QIIME, R and bioconducter
1
0
Entering edit mode
trichter • 0
@trichter-12658
Last seen 5.6 years ago

I try to run http://qiime.org/scripts/normalize_table.html on my data. The script requires R with Biocondcuctor.

The environment is Ubuntu 14.04 LTS, R 3.3.3 (/usr/bin/R) and QIIME 1.9.

The script has halted at several points, in which R couldnt find specific libraries, e.g. optparse, (installed from repository), biom (installed from local file, as it is not available for 3.3.3), and biomformat (installed via bioclite).

Now, it breaks again giving this output:

normalize_table.py -i otu_table.biom -a CSS -o CSS_normalized_otu_table.biom
Traceback (most recent call last):
  File "/opt/qiime-1.9.0/usr/local/bin/normalize_table.py", line 142, in <module>
    main()
  File "/opt/qiime-1.9.0/usr/local/bin/normalize_table.py", line 125, in main
    normalize_CSS(input_path, out_path, output_CSS_statistics)
  File "/opt/qiime-1.9.0/usr/local/lib/python2.7/dist-packages/qiime/normalize_table.py", line 38, in normalize_CSS
    run_CSS(temp_fh.name, out_path, output_CSS_statistics=output_CSS_statistics)
  File "/opt/qiime-1.9.0/usr/local/lib/python2.7/dist-packages/qiime/normalize_table.py", line 76, in run_CSS
    app_result = rsl(command_args=command_args, script_name='CSS.r')
  File "/opt/qiime-1.9.0/usr/local/lib/python2.7/dist-packages/qiime/util.py", line 1946, in __call__
    (exit_status, command, stdout, stderr))
burrito.util.ApplicationError: Unacceptable application exit status: 1
command: cd "/media/4tb/trichter/ScaleMic/Analysis_2017/OTU_picker/results/";  R --slave --args --source_dir /opt/qiime-1.9.0/usr/local/lib/python2.7/dist-packages/qiime/support_files/R -i /tmp/QIIME-normalize-table-temp-table-y1HnW4.biom -o CSS_normalized_otu_table.biom  < /opt/qiime-1.9.0/usr/local/lib/python2.7/dist-packages/qiime/support_files/R/CSS.r
stdout:

stderr:
Loading required namespace: biomformat
Error in if (!object$type %in% biomtypevals) { :
  argument is of length zero
Calls: CSS ... initialize -> validObject -> anyStrings -> validityMethod
In addition: Warning message:
'load_biom' is deprecated.
Use 'load_biom' instead.
See help("Deprecated") and help("metagenomeSeq-deprecated").
Execution halted

This all tells me, that i probably have a faulty setup of R, bioconductor, and QIIME. But i dont know how to fix this problem without guidance.

Here are my library paths of R. Note, that R-Studio (1.xxx, latest version) gives me a User Library, and a System Library (which doesnt happen with windows). R is not included in path, as per .bashrc, but can be run from shell.

[1] "/media/4tb/trichter/R/x86_64-pc-linux-gnu-library/3.3"
[2] "/usr/local/lib/R/site-library"                        
[3] "/usr/lib/R/site-library"                              
[4] "/usr/lib/R/library" 

here is a session.info

> sessionInfo()
R version 3.3.3 (2017-03-06)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 14.04 LTS

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

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

other attached packages:
[1] BiocInstaller_1.24.0

loaded via a namespace (and not attached):
[1] tools_3.3.3
R qiime • 2.5k views
ADD COMMENT
1
Entering edit mode
@james-w-macdonald-5106
Last seen just now
United States

This isn't really the place to be asking for help. QIIME isn't a Bioconductor package, and you are using R code that comes as part of QIIME, not Bioconductor. It's just happenstance that the code uses a Bioc package to do its thing.

It's also not clear that this has anything to do with your installation. The error you get is really saying that the test of object$type %in% biometypevals is returning a logical(0), which has a length of zero. This will occur if for instance object$type is NULL, or if object is a list that doesn't have a type member:

> object <- list(type = NULL)
> object$type %in% "whatevs"
logical(0)
> object <- list(whatevs = "whatevs")
> object$type %in% "whatevs"
logical(0)

And if we put that together in a fake test, we get

> if(!object$type %in% "whatevs") print(3)
Error in if (!object$type %in% "whatevs") print(3) :
  argument is of length zero

which is the error you see. But this is really a question you should be asking of the QIIME developers, or at their mailing list if they have one.

 

ADD COMMENT

Login before adding your answer.

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