[BioC] readAligned with bowtie2 input

Martin Morgan mtmorgan at fhcrc.org
Sun Dec 2 15:39:37 CET 2012


On 11/30/2012 08:06 AM, Maria Dermit wrote:
> Dear list,
>
> I am trying to read with some aligmnets files generated wiht Bowtie2 with
> readAligned function of ShortRead package with this code:
>
> readAligned("SRR030012.sra.1.aln.short.aln",type="Bowtie")
>
> and I get this error:
>
> error: unable to find an inherited method for function "strand", for
> signature "AlignedRead"
>
> I attach here the first 10 lines of one of my alignment files.

Hi Maria --

readAligned type="Bowtie" was introduced to read a format produced by earlier 
versions of Bowtie. My recommendation is that you arrange for Bowtie2 to 
generate BAM files, and then use Rsamtools::readBamGappedAlignments (which allow 
for more flexible input, and represents the data in the 'GenomicRanges' way.

Your packages are a mixture of 'release' and 'devel' versions, and I think also 
from different releases; you should

    source("http://bioconductor.org/biocLite.R")
    biocLite("BiocUpgrade")

It's a bit hard to see how 'strand' wouldn't be available after 
library(ShortRead); I see

 > showMethods(strand)
Function: strand (package BiocGenerics)
x="AlignedRead"
...

But I'm happy to investigate further if the problem persists. The attachment 
didn't get through the email, can you forward it to me privately?

Martin

>
> Many thanks for your help.
>
> Kind Regards,
>
> Maria
>
>> sessionInfo()
> R version 2.15.0 (2012-03-30)
> Platform: x86_64-unknown-linux-gnu (64-bit)
>
> locale:
>   [1] LC_CTYPE=en_GB.UTF-8       LC_NUMERIC=C
>   [3] LC_TIME=en_GB.UTF-8        LC_COLLATE=en_GB.UTF-8
>   [5] LC_MONETARY=en_GB.UTF-8    LC_MESSAGES=en_GB.UTF-8
>   [7] LC_PAPER=C                 LC_NAME=C
>   [9] LC_ADDRESS=C               LC_TELEPHONE=C
> [11] LC_MEASUREMENT=en_GB.UTF-8 LC_IDENTIFICATION=C
>
> attached base packages:
> [1] stats     graphics  grDevices utils     datasets  methods   base
>
> other attached packages:
> [1] ShortRead_1.12.4     latticeExtra_0.6-24  RColorBrewer_1.0-5
> [4] Rsamtools_1.9.30     lattice_0.20-10      Biostrings_2.25.12
> [7] GenomicRanges_1.9.59 IRanges_1.15.42      BiocGenerics_0.3.1
>
> loaded via a namespace (and not attached):
>   [1] Biobase_2.14.0      bitops_1.0-4.1      BSgenome_1.25.7
>   [4] grid_2.15.0         hwriter_1.3         RCurl_1.95-1.1
>   [7] rtracklayer_1.17.19 stats4_2.15.0       tools_2.15.0
> [10] XML_3.95-0.1        zlibbioc_1.4.0
>
>
>
> _______________________________________________
> Bioconductor mailing list
> Bioconductor at r-project.org
> https://stat.ethz.ch/mailman/listinfo/bioconductor
> Search the archives: http://news.gmane.org/gmane.science.biology.informatics.conductor
>


-- 
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



More information about the Bioconductor mailing list