Question: Detecting Overlaps within Grange Object
0
gravatar for user_g
20 months ago by
user_g20
user_g20 wrote:

Hello,

I have a Grange object which contains coordinates. I am using

findOverlaps()

function from the

GenomicRanges Package

inorder to detect overlaps. They provide 2 options, either minOverlap or maxGap. But I was trying to find a way to detect, maxOverlap or minGap. Is there a way to get to these options from the findOverlap function?

granges genomicranges R • 633 views
ADD COMMENTlink modified 20 months ago by d-cameron2.1k • written 20 months ago by user_g20
0
gravatar for d-cameron
20 months ago by
d-cameron2.1k
Australia
d-cameron2.1k wrote:

maxOverlap or minGap

These are exceedingly strange overlap requirements. What are you trying to do? Do you really want to do this?

If you really want these, then you should generate all possible pairings between query and subject, then removing the pairings that satisfy the corresponding minOverlap or maxGap criteria using the standard a findOverlaps() invocation.

For a non-overlapping granges with 1000 elements, a findOverlaps() with a maxOverlap or minGap of 0 of the granges object with itself will return 999,000 "overlaps" (all 1000*1000 combinations minus the 1000 self overlaps that actually overlap). Are you sure this is what you actually want to do?

ADD COMMENTlink modified 20 months ago • written 20 months ago by d-cameron2.1k
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: 1367 users visited in the last hour