[BioC] distanceToNearest for GRanges?
jayoung at fhcrc.org
Mon Aug 20 20:57:17 CEST 2012
Valerie Obenchain <vobencha at ...> writes:
> Hi Malcom,
> For distanceToNearest() I started with the ranges method in IRanges.
> Along the way I did find that distance,GenomicRanges,GenomicRanges was
> not handling the situation of '*','-' and '*','+' strand pairs (simply
> returning NA). Now those strand combinations are considered compatible
> just as '-','-' and '+','+' are.
> Let me know if you run into problems with the method or have other
> Take care,
I'm revisiting this older string.
I'm still using the release versions of GenomicRanges and IRanges (I want to
spend a little time figuring out the useDevel stuff, but the pressure is on
to think about biology right now, and it seems it might be better for me
to stick to the release versions).
That means distanceToNearest isn't available for GRanges in the version I'm
using, so I'm using a variant of Malcolm's function (thanks again!).
However, I realized that I'm running into the same issue with strands
that you brought up, Valerie, that "*"/"+" pairs were not recognized.
For now I'll try to remember to "unstrand" my GRanges objects before using
nearest, but I wondered if it's possible to update the nearest function in
the release version of IRanges so that it deals with the strands better?
More information about the Bioconductor