User:Lindenb/Notebook/UMR915/20110628

From OpenWetWare
Jump to: navigation, search
Owwnotebook icon.png

20110616        Top        20110704       


java api for bigwig/bigbed

svn checkout http://bigwig.googlecode.com/svn/trunk/ bigwig-read-only
cd bigwig-read-only
ant

Buildfile: build.xml

compile:
    [mkdir] Created dir: /home/lindenb/src/bigwig-read-only/build
    [javac] Compiling 38 source files to /home/lindenb/src/bigwig-read-only/build
    [javac] Note: /home/lindenb/src/bigwig-read-only/src/org/broad/igv/bbfile/BPTree.java uses unchecked or unsafe operations.
    [javac] Note: Recompile with -Xlint:unchecked for details.

dist:
    [mkdir] Created dir: /home/lindenb/src/bigwig-read-only/dist
      [jar] Building jar: /home/lindenb/src/bigwig-read-only/dist/BigWig.jar

BUILD SUCCESSFUL
Total time: 3 seconds

<html><script src="https://gist.github.com/1050793.js?file=BigCat.java"></script></html>

Compile

javac -cp ~/src/bigwig-read-only/dist/BigWig.jar:. BigCat.java

Exec:

java -cp /home/lindenb/src/bigwig-read-only/dist/BigWig.jar:/home/lindenb/src/bigwig-read-only/lib/log4j-1.2.15.jar:. BigCat ~/src/bigwig-read-only/test/data/chr21.bb  | head
chr21	9434178	9434609	
chr21	9434178	9434609	
chr21	9508110	9508214	
chr21	9516607	9516987	
chr21	9903013	9903230	
chr21	9903013	9903230	
chr21	9905661	9906613	
chr21	9907217	9907519	
chr21	9907241	9907415	
chr21	9907597	9908258

$ java -cp /home/lindenb/src/bigwig-read-only/dist/BigWig.jar:/home/lindenb/src/bigwig-read-only/lib/log4j-1.2.15.jar:. BigCat -p chr21:9906000-9908000 ~/src/bigwig-read-only/test/data/chr21.bb  | head
chr21	9905661	9906613	
chr21	9907217	9907519	
chr21	9907241	9907415	
chr21	9907597	9908258	

$ java -cp /home/lindenb/src/bigwig-read-only/dist/BigWig.jar:/home/lindenb/src/bigwig-read-only/lib/log4j-1.2.15.jar:. BigCat -p chr21:9906000-9908000 -c ~/src/bigwig-read-only/test/data/chr21.bb  | head
chr21	9907217	9907519	
chr21	9907241	9907415

$ java -cp /home/lindenb/src/bigwig-read-only/dist/BigWig.jar:/home/lindenb/src/bigwig-read-only/lib/log4j-1.2.15.jar:. BigCat  ~/src/bigwig-read-only/test/data/wigVarStepExample.bw  | head
chr21	9411190	9411195	50.0
chr21	9411195	9411200	40.0
chr21	9411200	9411205	60.0
chr21	9411205	9411210	20.0
chr21	9411210	9411215	20.0
chr21	9411215	9411220	20.0
chr21	9411220	9411225	40.0
chr21	9411225	9411230	60.0
chr21	9411230	9411235	40.0
chr21	9411235	9411240	40.0

$ java -cp /home/lindenb/src/bigwig-read-only/dist/BigWig.jar:/home/lindenb/src/bigwig-read-only/lib/log4j-1.2.15.jar:. BigCat -p chr21:9906000-9908000 ~/src/bigwig-read-only/test/data/wigVarStepExample.bw  | head
chr21	9906000	9906005	20.0
chr21	9906005	9906010	60.0
chr21	9906010	9906015	60.0
chr21	9906015	9906020	60.0
chr21	9906020	9906025	80.0
chr21	9906025	9906030	60.0
chr21	9906030	9906035	40.0
chr21	9906035	9906040	80.0
chr21	9906040	9906045	80.0
chr21	9906045	9906050	80.0