Skip to content
lindenb edited this page Oct 30, 2014 · 5 revisions

##Motivation

Convert UCSC LiftOver chain files ( https://genome.ucsc.edu/goldenPath/help/chain.html ) to animated SVG.

##Compilation

See also Compilation.

$  ant liftover2svg

##Synopsis

$ java -jar dist/liftover2svg.jar [options] (stdin|file1.chain file2.chain ...) 

##Options

Option Description
-t (float) seconds per step. Default:20.0
-w (int) width. Default:1000
-b (string) add this build name. Optional , multiple
-h get help (this screen) and exit.
-v print version and exit.
-L (level) log level. One of java.util.logging.Level . Optional.
--doap prints a DOAP+XML description of the program and exit

##Source Code

Main code is: https://github.com/lindenb/jvarkit/blob/master/src/main/java/com/github/lindenb/jvarkit/tools/liftover/LiftOverToSVG.java

Screenshot

https://twitter.com/yokofakun/status/525014376387215360

svg

##Examples

Examples 1

hg16 to hg38 http://cardioserve.nantes.inserm.fr/~lindenb/liftover2svg/hg16ToHg38.svg

BIG FILE : hg38 to panTro4 http://cardioserve.nantes.inserm.fr/~lindenb/liftover2svg/hg38ToPanTro4.svg

Example 2

create a SVG file for hg16 to hg38.

.PHONY:all 
all: test.svg


test.svg: hg16ToHg17.over.chain hg17ToHg18.over.chain hg18ToHg19.over.chain hg19ToHg38.over.chain dist/liftover2svg.jar
	java -jar dist/liftover2svg.jar -b hg16 -b hg17 -b hg18 -b hg19 -b hg38 \
			 hg16ToHg17.over.chain hg17ToHg18.over.chain hg18ToHg19.over.chain hg19ToHg38.over.chain > $@

hg16ToHg17.over.chain : 
	curl -s "http://hgdownload-test.cse.ucsc.edu/goldenPath/hg16/liftOver/$@.gz" | gunzip -c |\
	grep chain > $@

hg17ToHg18.over.chain : 
	curl -s "http://hgdownload-test.cse.ucsc.edu/goldenPath/hg17/liftOver/$@.gz" | gunzip -c |\
	grep chain > $@

hg18ToHg19.over.chain : 
	curl -s "http://hgdownload-test.cse.ucsc.edu/goldenPath/hg18/liftOver/$@.gz" | gunzip -c |\
	grep chain > $@
	
hg38ToPanTro4.over.chain :
	curl -s "http://hgdownload-test.cse.ucsc.edu/goldenPath/hg38/liftOver/$@.gz" | gunzip -c |\
	grep chain > $@

hg19ToHg38.over.chain hg19ToPanTro4.over.chain :
	curl -s "http://hgdownload-test.cse.ucsc.edu/goldenPath/hg19/liftOver/$@.gz" | gunzip -c |\
	grep chain > $@


dist/liftover2svg.jar: ./src/main/java/com/github/lindenb/jvarkit/tools/liftover/LiftOverToSVG.java
	ant liftover2svg

##See also

##History

  • 2014: Creation
Clone this wiki locally