[BioC] rtracklayer\'s browseGenome function failes when invoked according to vignette

Marcel Schilling [guest] guest at bioconductor.org
Mon Feb 24 16:40:24 CET 2014


I went through the rtracklayer vignette and got the following error:

> library('rtracklayer')
> data(targets)
> targetRanges <- IRanges(targets$start,targets$end)
> targetTrack <-with(targets,GRangesForUCSCGenome("hg18",chrom,targetRanges,strand,name,target))
> subTargetTrack <- targetTrack[1]
> browseGenome(subTargetTrack)
Error in as.vector(x, "character") : 
  cannot coerce type 'closure' to vector of type 'character'
> traceback()
12: as.character.default(call[[1L]])
11: as.character(call[[1L]])
10: callGeneric()
9: .local(object, range, track, ...)
8: (function (object, range, track, ...) 
   standardGeneric("browserView"))(<S4 object of class "UCSCSession">, 
       <S4 object of class "CompressedIRangesList">)
7: (function (object, range, track, ...) 
   standardGeneric("browserView"))(<S4 object of class "UCSCSession">, 
       <S4 object of class "CompressedIRangesList">)
6: do.call(browserView, viewParams)
5: .local(object, ...)
4: browseGenome(as(object, "RangedData"), ...)
3: browseGenome(as(object, "RangedData"), ...)
2: browseGenome(subTargetTrack)
1: browseGenome(subTargetTrack)

Interestingly, the following works as expected:
> browseGenome(subTargetTrack,range=base::range(subTargetTrack))

To me, this seems to be a bug, since the I copied the code from the vignette and it failed.
Of course, I might just be missing something.

 -- output of sessionInfo(): 

R version 3.0.2 (2013-09-25)
Platform: x86_64-pc-linux-gnu (64-bit)

locale:
 [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C               LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8     LC_MONETARY=en_US.UTF-8   
 [6] LC_MESSAGES=en_US.UTF-8    LC_PAPER=en_US.UTF-8       LC_NAME=C                  LC_ADDRESS=C               LC_TELEPHONE=C            
[11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C       

attached base packages:
[1] parallel  stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
[1] rtracklayer_1.22.3   GenomicRanges_1.14.4 XVector_0.2.0        IRanges_1.20.6       BiocGenerics_0.8.0   vimcom_0.9-93       

loaded via a namespace (and not attached):
[1] Biostrings_2.30.1 bitops_1.0-6      BSgenome_1.30.0   RCurl_1.95-4.1    Rsamtools_1.14.3  stats4_3.0.2      tools_3.0.2       XML_3.98-1.1     
[9] zlibbioc_1.8.0

--
Sent via the guest posting facility at bioconductor.org.



More information about the Bioconductor mailing list