jbisanz/qiime2R

New error with read_qza for table.qza?

Closed this issue · 4 comments

Hi,

First, thank you for this package, I've used it a lot in the past and it's saved me a ton of time.

I'm having an issue with the read_qza function when I try to read an ASV table. I'm using qiime2-2020.2 and the latest version of qiime2R. This is a table that I'm generating within R and importing into qiime2. I don't get any issues within qiime, and I recall being able to run this command without issue last time I used this package (months ago), so hopefully this is something we can clear up!

Here's the error:

> SVs <- read_qza("asv_table.qza")
Error in dimnamesGets(x, value) :
  invalid dimnames given for “dgCMatrix” object
Calls: read_qza ... colnames<- -> dimnames<- -> dimnames<- -> dimnamesGets
Execution halted

Here's my session info:

               _                           
platform       x86_64-pc-linux-gnu         
arch           x86_64                      
os             linux-gnu                   
system         x86_64, linux-gnu           
status                                     
major          3                           
minor          6.2                         
year           2019                        
month          12                          
day            12                          
svn rev        77560                       
language       R                           
version.string R version 3.6.2 (2019-12-12)
nickname       Dark and Stormy Night       
> library(qiime2R)
> session.info()
Error in session.info() : could not find function "session.info"
> sessionInfo()
R version 3.6.2 (2019-12-12)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Red Hat Enterprise Linux Server 7.7 (Maipo)

Matrix products: default
BLAS:   /usr/lib64/libblas.so.3.4.2
LAPACK: /usr/lib64/liblapack.so.3.4.2

locale:
 [1] LC_CTYPE=en_US.utf8       LC_NUMERIC=C             
 [3] LC_TIME=en_US.utf8        LC_COLLATE=en_US.utf8    
 [5] LC_MONETARY=en_US.utf8    LC_MESSAGES=en_US.utf8   
 [7] LC_PAPER=en_US.utf8       LC_NAME=C                
 [9] LC_ADDRESS=C              LC_TELEPHONE=C           
[11] LC_MEASUREMENT=en_US.utf8 LC_IDENTIFICATION=C      

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

other attached packages:
[1] qiime2R_0.99.33

loaded via a namespace (and not attached):
 [1] Biobase_2.46.0      tidyr_1.0.2         jsonlite_1.6.1     
 [4] splines_3.6.2       foreach_1.5.0       Formula_1.2-3      
 [7] assertthat_0.2.1    stats4_3.6.2        phyloseq_1.30.0    
[10] latticeExtra_0.6-29 yaml_2.2.1          pillar_1.4.3       
[13] backports_1.1.5     lattice_0.20-40     glue_1.4.1         
[16] digest_0.6.25       RColorBrewer_1.1-2  XVector_0.26.0     
[19] checkmate_2.0.0     colorspace_1.4-1    htmltools_0.4.0    
[22] Matrix_1.2-18       plyr_1.8.6          pkgconfig_2.0.3    
[25] zlibbioc_1.32.0     purrr_0.3.3         scales_1.1.0       
[28] jpeg_0.1-8.1        htmlTable_1.13.3    tibble_3.0.0       
[31] mgcv_1.8-31         IRanges_2.20.2      ggplot2_3.3.0      
[34] DT_0.13             ellipsis_0.3.0      nnet_7.3-13        
[37] BiocGenerics_0.32.0 cli_2.0.2           survival_3.2-3     
[40] magrittr_1.5        crayon_1.3.4        fansi_0.4.1        
[43] nlme_3.1-145        MASS_7.3-51.5       foreign_0.8-76     
[46] truncnorm_1.0-8     vegan_2.5-6         tools_3.6.2        
[49] data.table_1.12.8   lifecycle_0.2.0     stringr_1.4.0      
[52] Rhdf5lib_1.8.0      S4Vectors_0.24.3    munsell_0.5.0      
[55] cluster_2.1.0       Biostrings_2.54.0   ade4_1.7-15        
[58] compiler_3.6.2      rlang_0.4.5         rhdf5_2.30.1       
[61] grid_3.6.2          iterators_1.0.12    biomformat_1.14.0  
[64] rstudioapi_0.11     htmlwidgets_1.5.1   igraph_1.2.5       
[67] base64enc_0.1-3     gtable_0.3.0        codetools_0.2-16   
[70] multtest_2.42.0     reshape2_1.4.3      R6_2.4.1           
[73] gridExtra_2.3       knitr_1.28          dplyr_0.8.5        
[76] Hmisc_4.4-0         permute_0.9-5       ape_5.3            
[79] stringi_1.4.6       parallel_3.6.2      NADA_1.6-1.1       
[82] Rcpp_1.0.4          vctrs_0.2.4         zCompositions_1.3.4
[85] rpart_4.1-15        acepack_1.4.1       png_0.1-7          
[88] tidyselect_1.0.0    xfun_0.12   

Would you be willing to send me your artifact so I can debug? I changed the method of biom import to avoid another bug in biomformat. I'm wondering if there could be some odd character in your sample names, or perhaps it could be something along the lines of sample names are numbers?

There are underscores and periods in the sample names, but that hasn't been a problem in the past. Also I'm still able to import older projects which have similar sample names. Can I send the artifact to you over email?

That would be great! Please send to jordan.bisanz@gmail.com.

fixed in update