[Bioc-sig-seq] GenomicFeatures vignette error

Vincent Carey stvjc at channing.harvard.edu
Wed Mar 3 00:14:04 CET 2010


you're a little behind on BSgenome version, but consider

values(tdata)$tx_id

etc., which may be the way to do what you want

On Tue, Mar 2, 2010 at 4:52 PM, joseph <jdsandjd at yahoo.com> wrote:
> Hello
>
> I tried to reproduce the analysis in GenomicFeatures vignette section 2.7.2 (Example: Retrieving data from an RNA-seq experiment);
> I got the error below. Can you please help me?
> Thanks
>
>
>> txdb <- loadFeatures(system.file("extdata", "UCSC_knownGene_sample.sqlite", package="GenomicFeatures"))
>> gr <- GRanges(seqnames = rep("chr5",4), ranges = IRanges(start = c(244620,244670,245804,247502), end = c(244652,244702,245836,247534)), strand = rep("+",4))
>> annotGR <- transcriptsByRanges(txdb, gr, columns=c("tx_id", "tx_name", "gene_id", "exon_id"))
>> OL <- findOverlaps(gr, annotGR, multiple=TRUE)
>> tdata <- annotGR[subjectHits(OL),]
>
>> table(tdata$tx_id)
> Error in x[[name, exact = FALSE]] :
>  missing '[[' method for Sequence class GRanges
>> table(unlist(tdata$gene_id))
> Error in x[[name, exact = FALSE]] :
>  missing '[[' method for Sequence class GRanges
> Error in unlist(tdata$gene_id) :
>  error in evaluating the argument 'x' in selecting a method for function 'unlist'
>>
>
>> sessionInfo()
> R version 2.11.0 Under development (unstable) (2010-02-21 r51163)
> x86_64-unknown-linux-gnu
>
> locale:
>  [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C
>  [3] LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8
>  [5] LC_MONETARY=C              LC_MESSAGES=en_US.UTF-8
>  [7] LC_PAPER=en_US.UTF-8       LC_NAME=C
>  [9] LC_ADDRESS=C               LC_TELEPHONE=C
> [11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C
>
> attached base packages:
> [1] stats     graphics  grDevices utils     datasets  methods   base
>
> other attached packages:
>  [1] GenomicFeatures.Mmusculus.UCSC.mm9_0.1.1
>  [2] GenomicFeatures_0.3.38
>  [3] ShortRead_1.5.18
>  [4] lattice_0.18-3
>  [5] BSgenome_1.15.10
>  [6] Biostrings_2.15.22
>  [7] IRanges_1.5.49
>  [8] rtracklayer_1.7.10
>  [9] RCurl_1.3-1
> [10] bitops_1.0-4.1
>
> loaded via a namespace (and not attached):
> [1] Biobase_2.7.4 biomaRt_2.3.4 DBI_0.2-5     grid_2.11.0   hwriter_1.1
> [6] RSQLite_0.8-3 tools_2.11.0  XML_2.6-0
>>
>
>
>
>        [[alternative HTML version deleted]]
>
> _______________________________________________
> Bioc-sig-sequencing mailing list
> Bioc-sig-sequencing at r-project.org
> https://stat.ethz.ch/mailman/listinfo/bioc-sig-sequencing
>



More information about the Bioc-sig-sequencing mailing list