DESeq2: invalid class “GRangesList” object
1
0
Entering edit mode
9.1 years ago
alesssia ▴ 580

Hi all,

I am not sure if this is the right place to ask this question, but I've just updated my DESeq2 package from version 1.4.5 to version 1.6.3 and my scripts are no longer working. Specifically, I get the following error when generating a DESeqDataSet object with the function DESeqDataSetFromMatrix:

Error in validObject(.Object) :
invalid class "GRangesList" object: number of rows in DataTable 'mcols(x)' must match length of 'x'

To replicate this error one may either use the example shown in the DESeq2 vignette:

library("pasilla")
library("Biobase")
data("pasillaGenes")
countData <- counts(pasillaGenes)
colData <- pData(pasillaGenes)[,c("condition","type")]
dds <- DESeqDataSetFromMatrix(countData = countData,
                              colData = colData,
                              design = ~ condition)

or the example shown in the DESeq2 Reference Manual:

countData <- matrix(1:4,ncol=2)
colData <- data.frame(condition=factor(c("a","b")))
dds <- DESeqDataSetFromMatrix(countData, colData, formula(~ condition))

Thanks in advance for your help,
Alessia

sessionInfo()
R version 3.1.0 (2014-04-10)
Platform: x86_64-unknown-linux-gnu (64-bit)

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=en_US.UTF-8    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] parallel  stats4    stats     graphics  grDevices utils     datasets
[8] methods   base

other attached packages:
[1] DESeq2_1.6.3            RcppArmadillo_0.4.400.0 Rcpp_0.11.2
[4] GenomicRanges_1.16.4    GenomeInfoDb_1.0.2      IRanges_1.22.10
[7] S4Vectors_0.4.0         BiocGenerics_0.12.1     BiocInstaller_1.16.1

loaded via a namespace (and not attached):
 [1] acepack_1.3-3.3      annotate_1.42.1      AnnotationDbi_1.26.0
 [4] BatchJobs_1.3        BBmisc_1.7           Biobase_2.24.0
 [7] BiocParallel_0.6.1   brew_1.0-6           checkmate_1.4
[10] cluster_1.15.3       codetools_0.2-9      colorspace_1.2-4
[13] DBI_0.3.0            digest_0.6.4         fail_1.2
[16] foreach_1.4.2        foreign_0.8-61       Formula_1.1-2
[19] genefilter_1.46.1    geneplotter_1.42.0   ggplot2_1.0.0
[22] grid_3.1.0           gtable_0.1.2         Hmisc_3.14-5
[25] iterators_1.0.7      lattice_0.20-29      latticeExtra_0.6-26
[28] locfit_1.5-9.1       MASS_7.3-34          munsell_0.4.2
[31] nnet_7.3-8           plyr_1.8.1           proto_0.3-10
[34] RColorBrewer_1.0-5   reshape2_1.4         rpart_4.1-8
[37] RSQLite_0.11.4       scales_0.2.4         sendmailR_1.1-2
[40] splines_3.1.0        stringr_0.6.2        survival_2.37-7
[43] tools_3.1.0          XML_3.98-1.1         xtable_1.7-4
[46] XVector_0.4.0

Bioconductor version 3.0 (BiocInstaller 1.16.1)
DESeq2 bioconductor r • 3.8k views
ADD COMMENT
1
Entering edit mode

I would guess that this is an incompatibility with the version of GenomicRanges you have. The problematic code works on my system:

R version 3.1.2 (2014-10-31)
Platform: x86_64-pc-linux-gnu (64-bit)

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=en_US.UTF-8    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] stats4    parallel  stats     graphics  grDevices utils     datasets
[8] methods   base

other attached packages:
 [1] DESeq2_1.6.3              RcppArmadillo_0.4.650.1.1
 [3] Rcpp_0.11.4               GenomicRanges_1.18.4
 [5] GenomeInfoDb_1.2.4        IRanges_2.0.1
 [7] S4Vectors_0.4.0           pasilla_0.5.1
 [9] BiocInstaller_1.16.1      Biobase_2.26.0
[11] BiocGenerics_0.12.1

loaded via a namespace (and not attached):
 [1] acepack_1.3-3.3      annotate_1.44.0      AnnotationDbi_1.28.1
 [4] base64enc_0.1-2      BatchJobs_1.5        BBmisc_1.9
 [7] BiocParallel_1.0.3   brew_1.0-6           checkmate_1.5.1
[10] cluster_2.0.1        codetools_0.2-10     colorspace_1.2-4
[13] DBI_0.3.1            digest_0.6.8         fail_1.2
[16] foreach_1.4.2        foreign_0.8-62       Formula_1.2-0
[19] genefilter_1.48.1    geneplotter_1.44.0   ggplot2_1.0.0
[22] grid_3.1.2           gtable_0.1.2         Hmisc_3.15-0
[25] iterators_1.0.7      lattice_0.20-29      latticeExtra_0.6-26
[28] locfit_1.5-9.1       MASS_7.3-37          munsell_0.4.2
[31] nnet_7.3-8           plyr_1.8.1           proto_0.3-10
[34] RColorBrewer_1.1-2   reshape2_1.4.1       rpart_4.1-8
[37] RSQLite_1.0.0        scales_0.2.4         sendmailR_1.2-1
[40] splines_3.1.2        stringr_0.6.2        survival_2.37-7
[43] tools_3.1.2          XML_3.98-1.1         xtable_1.7-4
[46] XVector_0.6.0
ADD REPLY
0
Entering edit mode

Yours, Devon, may be a good guess! I've tried to update 'GenomicRanges', obtaining the following error:

Error : .onLoad failed in loadNamespace() for 'XVector', details:
  call: get(name, envir = asNamespace(pkg), inherits = FALSE)
  error: object 'setDefaultSlotValue' not found
ERROR: lazy loading failed for package 'GenomicRanges'
* removing '/export71/home/aviscont/R/x86_64-unknown-linux-gnu-library/3.1/GenomicRanges'

then installed XVector and (again) GenomicRanges, that also updated the dependencies 'IRanges', 'GenomeInfoDb'. Now we have the same versions of all these packages. However, when loading DESeq2 I obtain the following message:

Error : objects 'metadata', 'isTRUEorFALSE', 'isSingleString' are not exported by 'namespace:IRanges'
Error: package or namespace load failed for 'DESeq2'

error that I obtain also when installing DESeq2 from scratch also when IRanges_2.0.1 is one of the attached packages. Any idea? Thanks a lot!

ADD REPLY
0
Entering edit mode

No clue there, these sorts of errors are always a real PITA to fix since often more than one package is borked.

ADD REPLY
1
Entering edit mode
9.1 years ago
Michael Love ★ 2.6k

Just to check, are you installing with biocLite()? If not, definitely always install with biocLite(), and if you are having issues, you should be typing [y] when asked if you want to update your other Bioc packages. See also Upgrading installed Bioconductor packages here http://bioconductor.org/install/#update-bioconductor-packages

ADD COMMENT
0
Entering edit mode

Yeah, I am installing with biocLite() and yeah, I always typed [y] when I was asked to update my other Bioconductor packages. It did not help this time :(

ADD REPLY
0
Entering edit mode

Feel free to post this to the Bioc support site: support.bioconductor.org

The Bioc core team has lots of experiences with edge cases and might have an idea what to do. If you do post there, just put a link from here to that post so people can follow the trail. Also, include the biocLite() calls and the sessionInfo().

ADD REPLY
0
Entering edit mode

Finally, changing the order of the updates I managed to have everything working. Thanks!

ADD REPLY

Login before adding your answer.

Traffic: 2111 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6