Sorry for the trivial question but I can't understand the numbers in the fraction of each feature in bedtools annotate
.
Example from website:
$ cat variants.bed
chr1 100 200 nasty 1 -
chr2 500 1000 ugly 2 +
chr3 1000 5000 big 3 -
$ cat genes.bed
chr1 150 200 geneA 1 +
chr1 175 250 geneB 2 +
chr3 0 10000 geneC 3 -
$ cat conserve.bed
chr1 0 10000 cons1 1 +
chr2 700 10000 cons2 2 -
chr3 4000 10000 cons3 3 +
$ cat known_var.bed
chr1 0 120 known1 -
chr1 150 160 known2 -
chr2 0 10000 known3 +
$ bedtools annotate -i variants.bed -files genes.bed conserve.bed known_var.bed
chr1 100 200 nasty 1 - 0.500000 1.000000 0.300000
chr2 500 1000 ugly 2 + 0.000000 0.600000 1.000000
chr3 1000 5000 big 3 - 1.000000 0.250000 0.000000
Why the result on the first third column is 0.3 ?
chr1 100 200 nasty 1 - 0.500000 1.000000 0.300000
Is it 30 bases overlap divided by 100 ?
$ cat known_var.bed
chr1 0 120 known1 -
chr1 150 160 known2 -
/
$ cat variants.bed
chr1 100 200 nasty 1 -
But then the 0.5
should be another value right ?
$ cat genes.bed
chr1 150 200 geneA 1 +
chr1 175 250 geneB 2 +
/
$ cat variants.bed
chr1 100 200 nasty 1 -
Should be 75/100 or .75.
cross posted: https://bioinformatics.stackexchange.com/questions/18012