
なんとなく論文誌Bioinformaticsを眺めていたら楽しげなツールがありましたので、軽くご紹介。バクテリアゲノムなどを扱っている方には興味を持っていただけるかと。
CGViewStothard P, Wishart DS. (2005) "Circular genome visualization and exploration using CGView" Bioinformatics, 21:537-9. (
PubMed)
CGViewはJavaで作られたアプリケーションで、XMLファイルやタブ区切りファイルを入力して環状ゲノムのマップを描くものです。出力ファイルもPNG, JPEGなど様々なフォーマットの使用が可能で、拡大縮小可能なマップも描けます。詳しくは
ギャラリーを見てください。ダウンロードは無償です。
CGView インストール以下、Windows XP SP2上のcygwinで動作確認してみました。
1. 本体とソースが入ったファイルcgview.zipを
ダウンロードして、解凍します。
2. cgviewディレクトリに入って以下のコマンドを打ちます。
$ java -jar cgview.jar -i cybercell.xml -o cybercell.png -f pngこれはcybercell.xmlファイルに描かれたマップのPNG画像を生成します。cgviewディレクトリ内で作業を追ってみます。いうまでもありませんが、
Java 1.4以上が必要です。
$ ls
NC_001849.ptt ca/ cybercell.xml genbank_to_cgview/ lib/ src/
README cgview.jar example_3_features.tab includes/ manifestinfo
$ which java
/cygdrive/c/Windows/system32/java
$ java -jar cgview.jar -i cybercell.xml -o cybercell.png -f png
Parsing XML input.
Drawing features......
Drawing tick marks.
Drawing legends.
The map has been drawn.
Writing picture to cybercell.pngこれでcybercell.pngという画像ファイルが出来るはずです。
3. CGViewは
CGView XMLフォーマット、
シンプルなタブ区切り、
NCBI pttフォーマット、の3つのフォーマットに対応しています。入力ファイルは.xml, .tab, .pttのいずれかの拡張子をつけます。Perlスクリプトgenbank_to_cgview.plはGenBank or EMBLファイルをCGView XMLファイルへと変換します。
genbank_to_cgviewというディレクトリにはこのPerlスクリプトとREADMEファイル、そしてサンプルとしてBorrelia burgdorferi plasmid cp9のコンプリート配列 (ファイル名NC_001904.gbk) が格納されています。なおこのスクリプトは
Bioperl 1.4以上が必要です。スクリプトの使用方法は以下のようになっています。
Usage: genbank_to_cgview.pl -i
inputfile -o
outputfile -s
size ('small', 'medium', or 'large')
$ cd genbank_to_cgview
$ perl genbank_to_cgview.pl -i NC_001904.gbk -o NC_001904.xml -s medium
Sliding window size of 100 bases used for gc and at skew plot.
Moving in increments of 2 bases.
Sliding window size of 100 bases used for gc and at plot.
Moving in increments of 2 bases.
$ cd ../
$ java -jar cgview.jar -i genbank_to_cgview/NC_001904.xml -o NC_001904.png -f png
-h NC_001904.html
Parsing XML input.
Drawing features................
Positioning and drawing 11 labels..........................
0 labels were removed.
Drawing tick marks.
Drawing legends.
The map has been drawn.
Writing picture to NC_001904.png
Writing HTML to NC_001904.html
これでPNG画像とHTMLファイルができます。他にもコマンドラインオプションはありますので、
こちらを参照してください。
NC_001904.html上記の説明は静的なPNG画像を作るためのものです。zoomableなものを作るには他を参照してください。←無責任w
いやー、こういうの論文の図などに入れるとカッコイイでしょう!?
関連サイト
CGView
http://wishart.biology.ualberta.ca/cgview/
posted by soreyuke at 14:37|
Comment(0)
|
TrackBack(0)
|
tools
|

|