On Wed, Jan 27, 2010 at 2:38 PM, Dario Strbenac <[email protected]>wrote:
> Hi all, > > I can't seem to get countOverlaps to work and from the documentation I seem > to be doing it the right way. When I replace countOverlaps by findOverlaps, > the last code line in this example works though. > > ----------------------------------------- > subjRanges <- mapply(IRanges, start = split(subjRegions$start, > subjRegions$chr), end = split(subjRegions$end, SubjRegions$chr)) > SubjRangesList <- do.call(RangesList, SubjRanges) > queryRanges <- mapply(IRanges, start = split(queryTable$genoStart, > queryTable$genoName), end = split(queryTable$genoEnd, queryTable$genoName)) > queryRangesList <- do.call(RangesList, queryRanges) > > counts <- countOverlaps(queryRangesList, SubjRangesList) > # gives : Error in function (classes, fdef, mtable) : > unable to find an inherited method for function "countOverlaps", for > signature "SimpleRangesList", "SimpleRangesList" > ----------------------------------------- > > What's really happening here ? > > This one is easy -- the countOverlaps() method really does not exist for RangesList. I just added it to devel. In the meantime, you can use sum(queryRangesList %in% SubjRangesList) to get the same answer. Hope that helps, Michael Thanks, > Dario. > > _______________________________________________ > Bioc-sig-sequencing mailing list > [email protected] > https://stat.ethz.ch/mailman/listinfo/bioc-sig-sequencing > [[alternative HTML version deleted]] _______________________________________________ Bioc-sig-sequencing mailing list [email protected] https://stat.ethz.ch/mailman/listinfo/bioc-sig-sequencing
