Hi Xiaobei,

Thanks for reporting this bug! The problem was with how the "*" strand 
was assigned to a GRangesList when ignore.strand = TRUE. This is now 
fixed in GenomicRanges in devel 1.9.45 and release 1.8.12 in release. 
Both versions will be available through biocLite() tomorrow morning PST 
or through svn immediately.

Valerie


On 08/10/2012 09:07 AM, xiaobei.zhou@uzh.ch wrote:
> Hello everyone,
>
> Maybe "I've found an error running summarizeOverlaps()" ...
>
> This is what the example in summarizeOverlaps() does:
> -------------------------------------------------------------------------------------------------------------------------
>> Â 
>> ## paired-end readsÂ 
>> ##
>> Â 
>> library("TxDb.Dmelanogaster.UCSC.dm3.ensGene")
>> exbygene<- exonsBy(TxDb.Dmelanogaster.UCSC.dm3.ensGene, "gene")
>> fl<- system.file("extdata", "untreated3_chr4.bam",Â 
>> Â  Â  package="pasillaBamSubset")Â 
>> Â 
>> ## Paired-end reads are stored in a GappedAlignmentPairs object
>> reads<- readGappedAlignmentPairs(fl)
>> Â 
>> res<- summarizeOverlaps(exbygene, reads, "Union")
>> stopifnot(length(assays(res)$counts) == length(exbygene))
>> Â 
>> -------------------------------------------------------------------------------
>
> I run exactly the same example but with ignore.strand = TRUE.Â 
> Then it gives an error:
>
>
>>> library("TxDb.Dmelanogaster.UCSC.dm3.ensGene")
>>> exbygene<- exonsBy(TxDb.Dmelanogaster.UCSC.dm3.ensGene, "gene")
>>> fl<- system.file("extdata", "untreated3_chr4.bam",Â
>> + Â  Â  package="pasillaBamSubset")Â
>>> Â 
>>> ## Paired-end reads are stored in a GappedAlignmentPairs object
>>> reads<- readGappedAlignmentPairs(fl)
>> Â
>>>> res<- summarizeOverlaps(exbygene, reads, "Union", ignore.strand = TRUE)
>>> Error in .local(x, ..., value) :Â
>> Â  replacement 'value' is not an AtomicList with the same elementLengths as 'x'
>>>> traceback()
>>> 7: stop("replacement 'value' is not an AtomicList with the same ",Â
>> Â  Â  Â  Â "elementLengths as 'x'")
>>> 6: .local(x, ..., value)
>>> 5: `strand<-`(`*tmp*`, value = "*")
>>> 4: `strand<-`(`*tmp*`, value = "*")
>>> 3: .dispatchOverlaps(grglist(reads), features, mode, ignore.strand)
>>> 2: summarizeOverlaps(exbygene, reads, "Union", ignore.strand = TRUE)
>>> 1: summarizeOverlaps(exbygene, reads, "Union", ignore.strand = TRUE)
>> Â 
>> Â
>>>> Â sessionInfo()
>>> R version 2.15.1 (2012-06-22)
>>> Platform: x86_64-unknown-linux-gnu (64-bit)
>> Â
>>> locale:
>>> [1] LC_CTYPE=en_CA.UTF-8 Â  Â  Â  LC_NUMERIC=C Â  Â  Â  Â  Â  Â  Â 
>>> [3] LC_TIME=en_CA.UTF-8 Â  Â  Â  Â LC_COLLATE=en_CA.UTF-8 Â  Â 
>>> [5] LC_MONETARY=en_CA.UTF-8 Â  Â LC_MESSAGES=en_CA.UTF-8 Â Â 
>>> [7] LC_PAPER=C Â  Â  Â  Â  Â  Â  Â  Â  LC_NAME=C Â  Â  Â  Â  Â  Â  Â  Â Â 
>>> [9] LC_ADDRESS=C Â  Â  Â  Â  Â  Â  Â  LC_TELEPHONE=C Â  Â  Â  Â  Â  Â 
>>> [11] LC_MEASUREMENT=en_CA.UTF-8 LC_IDENTIFICATION=C Â  Â  Â Â
>> Â
>>> attached base packages:
>>> [1] stats Â  Â  graphics Â grDevices utils Â  Â  datasets Â methods Â  base Â  Â Â
>> Â
>>> other attached packages:
>>> [1] Rsamtools_1.9.25 Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â Â 
>>> [2] Biostrings_2.25.8 Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â 
>>> [3] rtracklayer_1.17.15 Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â 
>>> [4] TxDb.Dmelanogaster.UCSC.dm3.ensGene_2.7.1
>>> [5] GenomicFeatures_1.9.28 Â  Â  Â  Â  Â  Â  Â  Â  Â Â 
>>> [6] AnnotationDbi_1.19.28 Â  Â  Â  Â  Â  Â  Â  Â  Â  Â 
>>> [7] Biobase_2.17.6 Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â Â 
>>> [8] GenomicRanges_1.9.42 Â  Â  Â  Â  Â  Â  Â  Â  Â  Â Â 
>>> [9] IRanges_1.15.29 Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â 
>>> [10] BiocGenerics_0.3.0 Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â Â
>> Â
>>> loaded via a namespace (and not attached):
>>> [1] biomaRt_2.13.2 Â bitops_1.0-4.1 Â BSgenome_1.25.6 DBI_0.2-5 Â  Â  Â 
>>> [5] RCurl_1.91-1 Â  Â RSQLite_0.11.1 Â stats4_2.15.1 Â  tools_2.15.1 Â Â 
>>> [9] XML_3.9-4 Â  Â  Â  zlibbioc_1.3.0Â
> -----------------------------------------------------------------------------------------
> Â 
>
> Help much appreciated.
> Â 
> Best,
> Xiaobei
>
>
> =
> 	[[alternative HTML version deleted]]
>
>
>
> _______________________________________________
> Bioc-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/bioc-devel


	[[alternative HTML version deleted]]

