[BioC] Bug in GenomeGraphs: makeGeneRegion fails on regions devoid of genes

Simon Anders anders at ebi.ac.uk
Thu Jun 4 16:04:33 CEST 2009


Hi Steffen

I've just found a bug in GenomeGraphs. Try this code:

   library(GenomeGraphs)

   mart <- useMart("ensembl", dataset = "mmusculus_gene_ensembl")

   start <- 51000000
   end <-   51100000

   plusStrand <- makeGeneRegion( chromosome = 10, start = start,
      end = end, strand = "+", biomart = mart )

   gdPlot( list( plusStrand ) )

I get the error

   > gdPlot( list( plusStrand ) )
   Error in if (ens[1, 6] == 1) { : missing value where TRUE/FALSE needed

The reason seems to be that the indicated interval does not contain any 
genes. If you set 'end' to 52000000, it works correctly.

 > sessionInfo()
R version 2.9.0 (2009-04-17)
x86_64-unknown-linux-gnu

locale:
LC_CTYPE=en_GB.UTF-8;LC_NUMERIC=C;LC_TIME=en_GB.UTF-8;LC_COLLATE=en_GB.UTF-8;LC_MONETARY=C;LC_MESSAGES=en_GB.UTF-8;LC_PAPER=en_GB.UTF-8;LC_NAME=C;LC_ADDRESS=C;LC_TELEPHONE=C;LC_MEASUREMENT=en_GB.UTF-8;LC_IDENTIFICATION=C

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

other attached packages:
[1] GenomeGraphs_1.4.0 biomaRt_2.0.0

loaded via a namespace (and not attached):
[1] RCurl_0.94-1 XML_2.3-0


Cheers
   Simon


+---
| Dr. Simon Anders, Dipl. Phys.
| European Bioinformatics Institute, Hinxton, Cambridgeshire, UK
| office phone +44-1223-492680, mobile phone +44-7505-841692
| preferred (permanent) e-mail: sanders at fs.tum.de



More information about the Bioconductor mailing list