Question: Fraction of bases covered by each element in bed
0
gravatar for avinash.sahu
5.1 years ago by
avinash.sahu10
United States
avinash.sahu10 wrote:

I am stuck in finding special kind of intersect of 2 bed files. I want to find for each entry of a.bed fraction (or number) of base-pairs overlapping at least one element of b.bed ( ignoring strand).  b.bed itself can have overlapping enteries. For eg.

a.bed

chr1    1       21      A

chr1    13      24      B

b.bed

chr1    4       11      +    1

chr1    6       12     -    2

chr1    7       15     -    3

output should be

chr1    1       20      A     11 (7+1+3)     

chr1    13      24      B     2

 

Even if I can get unique overlap A those intersect one entry of B I can collapse them. However, bedtools-intersect reports non-unique overlap if b.bed enteries are overlapping. Any solution?

tool chip-seq R • 1.4k views
ADD COMMENTlink modified 5.1 years ago by Devon Ryan90k • written 5.1 years ago by avinash.sahu10
2
gravatar for avinash.sahu
5.1 years ago by
avinash.sahu10
United States
avinash.sahu10 wrote:

CoverageBed of bedtool perform exactly that I was referring to.  Sorry for the trivial question.
 

ADD COMMENTlink written 5.1 years ago by avinash.sahu10
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 1982 users visited in the last hour