Right, match.fun() needs to be within the initial endoapply, not later.
Isn't the convention though to use `obeyQname<-` in this case? Or should
there be a convention?


On Wed, Nov 20, 2013 at 5:18 PM, Martin Morgan <mtmor...@fhcrc.org> wrote:

> After this
>
>     library(RNAseqData.HNRNPC.bam.chr14)
>     library(TxDb.Hsapiens.UCSC.hg19.knownGene)
>     fls <- RNAseqData.HNRNPC.bam.chr14_BAMFILES
>     exByGn <- exonsBy(TxDb.Hsapiens.UCSC.hg19.knownGene, "gene")
>
> Rsamtools is loaded but not attached; it's 
> summarizeOverlaps,GRanges,character-method
> is available (maybe it shouldn't be, but that's a different question).
> Invoking
>
>     summarizeOverlaps(exByGn, fls)
>
> results in
>
> > summarizeOverlaps(exByGn, fls)
> Error in get(as.character(FUN), mode = "function", envir = envir) :
>   object 'obeyQname<-' of mode 'function' was not found
>
> with
>
> > traceback()
> 14: get(as.character(FUN), mode = "function", envir = envir)
> 13: match.fun(FUN)
> 12: lapply(as.list(X), FUN = FUN, ...)
> 11: lapply(as.list(X), FUN = FUN, ...)
> 10: lapply(X, FUN = FUN, ...)
> 9: lapply(X, FUN = FUN, ...)
> 8: endoapply(object, "obeyQname<-", value = value)
> 7: endoapply(object, "obeyQname<-", value = value)
> 6: `obeyQname<-`(`*tmp*`, value = FALSE)
> 5: `obeyQname<-`(`*tmp*`, value = FALSE)
> 4: BamFileList(reads, yieldSize = yieldSize, obeyQname = FALSE,
>        asMates = !singleEnd)
> 3: .local(features, reads, mode, ignore.strand, ...)
> 2: summarizeOverlaps(exByGn, fls)
> 1: summarizeOverlaps(exByGn, fls)
>
> and the parent.frame() of the environment (where the search at line 14
> starts) is IRanges, but should be Rsamtools (where endoapply was invoked).
>
> Martin
> --
> Computational Biology / Fred Hutchinson Cancer Research Center
> 1100 Fairview Ave. N.
> PO Box 19024 Seattle, WA 98109
>
> Location: Arnold Building M1 B861
> Phone: (206) 667-2793
>
> _______________________________________________
> Bioc-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/bioc-devel
>

        [[alternative HTML version deleted]]

_______________________________________________
Bioc-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/bioc-devel

Reply via email to