Question: how much positions overlapped for each pair of the pairs obtained by findoverlap.
0
gravatar for vinod.acear
3.7 years ago by
vinod.acear40
India
vinod.acear40 wrote:

I have got overlapping pairs list using findoverlap function on two granges, i want to know  how much positions overlapped for each  pair of  the pairs obtained by findoverlap.

ADD COMMENTlink modified 3.6 years ago by Hervé Pagès ♦♦ 14k • written 3.7 years ago by vinod.acear40
Answer: how much positions overlapped for each pair of the pairs obtained by findover
3
gravatar for Hervé Pagès
3.6 years ago by
Hervé Pagès ♦♦ 14k
United States
Hervé Pagès ♦♦ 14k wrote:

Hi,

So you have a Hits object that you got by calling findOverlaps() on your GRanges objects query and subject, e.g. by doing something like:

hits <- findOverlaps(query, subject, ...)

Now you can get the corresponding overlap as a range for each pair in hits with:

overlap <- pintersect(query[queryHits(hits)],
                      subject[subjectHits(hits)])

and the number of positions in each overlap with:

width(overlap)

Cheers,

H.

ADD COMMENTlink modified 3.6 years ago • written 3.6 years ago by Hervé Pagès ♦♦ 14k

Thanks herve

ADD REPLYlink written 3.6 years ago by vinod.acear40
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 16.09
Traffic: 212 users visited in the last hour