Question about custom tracks

46 views
Skip to first unread message

Alhawaj, Ali

unread,
Aug 5, 2021, 10:19:28 AM8/5/21
to gen...@soe.ucsc.edu

Good day,

 

I have a question regarding handling custom tracks in Hg19 vs Hg38 Genome browser. I couldn’t find the answer in the help & FAQ sections, and I hope that I could get some help from you.

 

I have received a session link with custom tracks in hg19, and I would like to transfer the track in hg38 browser.

 

I have clicked on the track name -> update custom track, then I copied the info shown and pasted it in a new custom track in hg38
the info is:

track type=bigWig name="S015UGH1" bigDataUrl=http://mbdata.science.ru.nl/share/yi/AML_RNA/S015UGH1_Aligned.sortedByCoord.bw

 

However, the data appeared shifted to a different genome location, as expected. It’s written in the link above that it’s Aligned.
How can I transfer this custom track to its new appropriate coordinates in hg38?

 

Session link:

https://genome.ucsc.edu/s/marcmansour/Yi%20RNA%2Dseq%20AML

 

Many thanks!

 

Ali Alhawaj

UCL Cancer institute

London, UK

Gerardo Perez

unread,
Aug 10, 2021, 10:52:59 PM8/10/21
to Alhawaj, Ali, gen...@soe.ucsc.edu

Hello, Ali.

Thank you for your interest in the Genome Browser and your question about transferring custom tracks from hg19 to hg38.

You could use the UCSC LiftOver tool to move annotations from one assembly to another. You can download the ‘liftOver’ utility from the downloads page, https://hgdownload.soe.ucsc.edu/downloads.html#utilities_downloads. You can then find ‘liftOver’ under the directory that matches your operating system. For example, here is the direct link for linux:
http://hgdownload.soe.ucsc.edu/admin/exe/linux.x86_64/liftOver

Our ‘liftOver’ tool only accepts BED files as input, so you would first need to convert the files from bigWig to bedGraph. You can use the ‘bigWigToBedGraph’ utility to make this conversion:
http://hgdownload.soe.ucsc.edu/admin/exe/linux.x86_64/bigWigToBedGraph

After running ‘liftOver’ on the bedGraph file, you could then use the 'bedGraphToBigWig' to convert it back into a bigWig file for display:
http://hgdownload.soe.ucsc.edu/admin/exe/linux.x86_64/bedGraphToBigWig

Our engineers shared a bit of code, that includes the 'bedRemoveOverlap' (http://hgdownload.soe.ucsc.edu/admin/exe/linux.x86_64/bedRemoveOverlap) and 'bedGraphPack' (http://hgdownload.soe.ucsc.edu/admin/exe/linux.x86_64/bedGraphPack) utilities, which you can run to remove overlapping items from the liftOver results file and merge adjacent records with identical scores:

bigWigToBedGraph $bigWigIn stdout \
| liftOver stdin $liftOverFile stdout /dev/null \
| sort -k1,1 -k2,2n \
| bedRemoveOverlap stdin stdout \
| bedGraphPack stdin $tmpFile

bedGraphToBigWig $tmpFile $chromSizes $bigWigOut

You can run a utility on its own to see a help message, e.x.

liftOver
liftOver - Move annotations from one assembly to another
usage:
   liftOver oldFile map.chain newFile unMapped
oldFile and newFile are in bed format by default, but can be in GFF and
maybe eventually others with the appropriate flags below.
The map.chain file has the old genome as the target and the new genome
as the query.

***********************************************************************
WARNING: liftOver was only designed to work between different
         assemblies of the same organism. It may not do what you want
         if you are lifting between different organisms. If there has
         been a rearrangement in one of the species, the size of the
         region being mapped may change dramatically after mapping.
***********************************************************************

options:
   -minMatch=0.N Minimum ratio of bases that must remap. Default 0.95
   -gff  File is in gff/gtf format.  Note that the gff lines are converted
         separately.  It would be good to have a separate check after this
         that the lines that make up a gene model still make a plausible gene
         after liftOver
   -genePred - File is in genePred format
   -sample - File is in sample format
   -bedPlus=N - File is bed N+ format (i.e. first N fields conform to bed format)
   -positions - File is in browser "position" format
   -hasBin - File has bin value (used only with -bedPlus)
   -tab - Separate by tabs rather than space (used only with -bedPlus)
   -pslT - File is in psl format, map target side only
   -ends=N - Lift the first and last N bases of each record and combine the
             result. This is useful for lifting large regions like BAC end pairs.
   -minBlocks=0.N Minimum ratio of alignment blocks or exons that must map
                  (default 1.00)
   -fudgeThick    (bed 12 or 12+ only) If thickStart/thickEnd is not mapped,
                  use the closest mapped base.  Recommended if using 
                  -minBlocks.
   -multiple               Allow multiple output regions
   -noSerial               In -multiple mode, do not put a serial number in the 5th BED column
   -minChainT, -minChainQ  Minimum chain size in target/query, when mapping
                           to multiple output regions (default 0, 0)
   -minSizeT               deprecated synonym for -minChainT (ENCODE compat.)
   -minSizeQ               Min matching region size in query with -multiple.
   -chainTable             Used with -multiple, format is db.tablename,
                               to extend chains from net (preserves dups)
   -errorHelp              Explain error messages

I hope this is helpful. If you have any further questions, please reply to gen...@soe.ucsc.edu. All messages sent to that address are archived on a publicly-accessible Google Groups forum. If your question includes sensitive data, you may send it instead to genom...@soe.ucsc.edu.

Gerardo Perez
UCSC Genomics Institute


--

---
You received this message because you are subscribed to the Google Groups "UCSC Genome Browser Public Support" group.
To unsubscribe from this group and stop receiving emails from it, send an email to genome+un...@soe.ucsc.edu.
To view this discussion on the web visit https://groups.google.com/a/soe.ucsc.edu/d/msgid/genome/DBAPR01MB70789B032AFB8CA16536613289F29%40DBAPR01MB7078.eurprd01.prod.exchangelabs.com.

Gerardo Perez

unread,
Aug 12, 2021, 8:30:21 PM8/12/21
to Alhawaj, Ali, gen...@soe.ucsc.edu

Hello, Ali.

To follow-up, you could also use Crossmap to perform the bigWig conversion directly without any other conversions. Crossmap accepts the same input files, our liftOver files, and the author says it gets almost the same results. You can learn more about the program from their website, http://crossmap.sourceforge.net/. Unfortunately, we do not maintain Crossmap
so we cannot provide guidance on how to use the tool. You may find posting any questions about
Crossmap on other bioinformatic forums such as BioStars, https://www.biostars.org/.

I hope this is helpful. If you have any further questions, please reply to gen...@soe.ucsc.edu. All messages sent to that address are archived on a publicly-accessible Google Groups forum. If your question includes sensitive data, you may send it instead to genom...@soe.ucsc.edu.

Gerardo Perez
UCSC Genomics Institute

On Thu, Aug 5, 2021 at 7:19 AM Alhawaj, Ali <ali.alh...@ucl.ac.uk> wrote:
--

Alhawaj, Ali

unread,
Aug 13, 2021, 11:08:51 AM8/13/21
to Gerardo Perez, gen...@soe.ucsc.edu

Thank you very much for the detailed reply!

Much appreciated!!

 

Ali

Reply all
Reply to author
Forward
0 new messages