genome graphに遺伝子のスタート座標を乗せよう。
bedgraphでカスタムトラックに追加してから、
インポートでgenome graphへ。
##----------------------------------------##
#
# note batch file for gb2bedgraph.pl
#
##----------------------------------------##
usage :
perl all_chrgb2bed.pl xxxx.gb outdir
for ex.
[hoge@boss5 rn4]# perl all_chr.gb2bed.pl rat_uniq_gene.gb rn4start_bedgraph
[hoge@boss5 rn4start_bedgraph]# ls
..........
[hoge@boss5 rn4start_bedgraph]# head chr1.start_gene.bedgraph
chr1 1306646 1306647 1
chr1 2394947 2394948 1
chr1 5975207 5975208 1
chr1 6051558 6051559 1
...............
[hoge@boss5 rn4start_bedgraph]# cat chr*.start_gene.bedgraph > all_chr.start_gene.bedgraph
genomegraph uploaded as a custom track in the UCSC genome browser
coverage select
#!/usr/bin/perl
#
# bacth file for bed and bedgraph
$| = 1;
@chrarr = ('1', '2', '3', '4', '5',
'6', '7', '8', '9', '10',
'11', '12', '13', '14', '15',
'16', '17', '18', '19', '20',
'X');
if ($#ARGV < 0) {
print STDERR "\n";
print STDERR "Usage: all_chr.gb2bed(graph).pl xxx.gb outdir\n\n";
exit;
} else {
$gbfile = $ARGV[0];
$outdir = $ARGV[1];
if (-d $outdir) {
print STDERR "\n";
print STDERR "ERROR: outdir, $outdir, alredy exists!!\n\n";
exit;
} else {
system("mkdir $outdir");
}
}
#$gb2bed = "gb2bed.pl";
$gb2bedgraph = "gb2bedgraph.pl";
$space = "\[\[\:space\:\]\]";
foreach $i (0..$#chrarr) {
$chr = "chr$chrarr[$i]";
$start_genefile = "$outdir/$chr.start_gene.bed";
#system("\grep \"$space$chr$space\" $gbfile | perl $gb2bed - > $start_genefile");
system("\grep \"$space$chr$space\" $gbfile | perl $gb2bedgraph - > $start_genefile");
}
[hoge@boss5 rn4]# perl all_chr.gb2bed.pl rat_uniq_gene.gb rn4start_bedgraph
##----------------------##
#
# gb2bedgraph.pl
#
##---------------------##
#!usr/bin/perl
#
##----------------------------------------##
#
# note batch file for gb2bedgraph.pl
#
##----------------------------------------##
usage :
perl all_chrgb2bed.pl xxxx.gb outdir
for ex.
[hoge@boss5 rn4]# perl all_chr.gb2bed.pl rat_uniq_gene.gb rn4start_bedgraph
[hoge@boss5 rn4start_bedgraph]# ls
chr1.start_gene.bedgraph chr15.start_gene.bedgraph chr20.start_gene.bedgraph chr8.start_gene.bedgraph
chr10.start_gene.bedgraph chr16.start_gene.bedgraph chr3.start_gene.bedgraph chr9.start_gene.bedgraph
..........
[hoge@boss5 rn4start_bedgraph]# head chr1.start_gene.bedgraph
このように
chr start(0始まりのgene) start+1 高さ1 (適当に全部同じ高さ)
chr1 1306646 1306647 1
chr1 2394947 2394948 1
chr1 5975207 5975208 1
chr1 6051558 6051559 1
...............
こんなフォーマットで作ってみた。
[hoge@boss5 rn4start_bedgraph]# cat chr*.start_gene.bedgraph > all_chr.start_gene.bedgraph
genomegraph uploaded as a custom track in the UCSC genome browser
coverage select
genome graphに遺伝子のスタート座標を乗せよう。
bedgraphでカスタムトラックに追加してから、
インポートでgenome graphへ。
①普通のゲノムブラウザにaddカスタムトラックする。
②ゲノムブラウザに飛ぶとこんな感じ。
gene startに|||||| ||||| || || と並ぶ。
③先ほどのカスタムトラックに入れたのをゲノムグラフでインポート
Custum tracks rn4gene
table: ct_rn4gene_5451(勝手に番号が付いているみたい)
・ depth を選択。
1000000000 base と入力。
submit する。
④ゲノムブラウザにrn4gene_011を選択。
⑤なんかdepthまあ違ったっぽい。
⑥importへ。
⑦import table to genome graphsのページで今度はcoverageを選択する。
⑧ゲノムブラウザでこれを見てみると、
^^^^ ^^^ ^ このような形でcoverageが示される。