DESeq2 DESeqDataSetFromMatrix problem
3
0
Entering edit mode
Rao,Xiayu ▴ 550
@raoxiayu-6003
Last seen 8.9 years ago
United States

Dear list, 

I encountered a strange problem when using the DESeqDataSetFromMatrix command from DESeq2. I have set up the countData and colData in the required format the same as the sample data described in the tutorial. The column names of the countdata refer to samples, while the row names refer to genes. The row number of colData is the same as the samples. What causes the problem and how to fix it? 

Any input would be very appreciated! Thank you!

Thanks,

Xiayu

 

> colData
                      condition
HOSC1-cellline    HPVpos
UD-SCC2           HPVpos
UM-SCC104         HPVpos
UM-SCC47          HPVpos
UPCI_SCC090       HPVpos
UPCI_SCC152       HPVpos
UPCI_SCC154       HPVpos
UT-SCC45          HPVpos
VU-147T           HPVpos
1483              HPVneg
183               HPVneg
....


> head(countdata[,1:11])
       HOSC1-cellline UD-SCC2 UM-SCC104 UM-SCC47 UPCI_SCC090 UPCI_SCC152
A1BG                2       0         1        0          80          65
A1CF                0       0         0        0           0           0
A2M                 3       0         0        0           1           0
A2ML1             157       1       190       21         759         747
A4GALT            625       0       780      590         346        1134
A4GNT               0       0         0        0           1           0
       UPCI_SCC154 UT-SCC45 VU-147T 1483  183
A1BG             6        9       3   53   30
A1CF             0        0       0    1    5
A2M              1        0       1    2    1
A2ML1            1       32       4   14 2280
A4GALT         630      235    1414  107 2072
A4GNT            2        0       0    1    1


> dds <- DESeqDataSetFromMatrix(countData = countdata, colData = colData, design = ~ condition)
Error in validObject(.Object) : 
  invalid class RangesList?object: number of rows in DataTable 'mcols(x)' must match length of 'x'


> 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.320.0 Rcpp_0.11.3            
[4] GenomicRanges_1.16.4    GenomeInfoDb_1.0.2      IRanges_1.22.10        
[7] S4Vectors_0.4.0         BiocGenerics_0.12.1    

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

deseq2 • 4.7k views
ADD COMMENT
0
Entering edit mode
@mikelove
Last seen 1 day ago
United States
Can you check dim(countdata) dim(coldata) class(coldata) ?
ADD COMMENT
0
Entering edit mode

> dim(countdata)
[1] 20587    69

> dim(colData)
[1] 69  1

> class(colData)
[1] "data.frame"

Thank you for your reply!

ADD REPLY
0
Entering edit mode
Try my other suggestion below
ADD REPLY
0
Entering edit mode
@mikelove
Last seen 1 day ago
United States
Try updating IRanges and GenomicRanges. It appears these are not up to the current release version.
ADD COMMENT
0
Entering edit mode
Rao,Xiayu ▴ 550
@raoxiayu-6003
Last seen 8.9 years ago
United States

Problem solved. It turns out to be the library issue in the linux system. The code should be fine. Thank you all and Merry Christmas!

ADD COMMENT

Login before adding your answer.

Traffic: 1031 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