Problem with ALDEx2

Hi!
I am trying to run ALDEx2 in qiime2-2020.2 version. But I get this error:

Plugin error from aldex2:

** An error was encountered while running ALDEx2 in R (return code 1), please inspect stdout and stderr to learn more.**

Debug info has been saved to /tmp/qiime2-q2cli-err-31aztdjt.log
log file:

Running external command line application(s). This may print messages to stdout and/or stderr.
The command(s) being run are below. These commands cannot be manually re-run as they will depend on temporary files that no longer exist.

Command: run_aldex2.R /tmp/tmpiwex_o1o/input.tsv.biom /tmp/tmpiwex_o1o/input.map.txt sample 128 t all /tmp/tmpiwex_o1o/output.summary.txt

R version 3.5.1 (2018-07-02)
[1] “aldex.clr: generating Monte-Carlo instances and clr values”
[1] “operating in serial mode”
[1] “computing center with all features”
[1] “aldex.ttest: doing t-test”
Error in aldex.ttest(x, conditions, paired.test = FALSE) :
only two condition levels are currently supported
Calls: aldex -> aldex.ttest
EjecuciĂłn interrumpida
Traceback (most recent call last):
File “/home/cristian/miniconda3/envs/qiime2-2020.2/lib/python3.6/site-packages/q2_aldex2/_method.py”, line 59, in aldex2
run_commands([cmd])
File “/home/cristian/miniconda3/envs/qiime2-2020.2/lib/python3.6/site-packages/q2_aldex2/_method.py”, line 21, in run_commands
subprocess.run(cmd, check=True)
File “/home/cristian/miniconda3/envs/qiime2-2020.2/lib/python3.6/subprocess.py”, line 418, in run
output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command ‘[‘run_aldex2.R’, ‘/tmp/tmpiwex_o1o/input.tsv.biom’, ‘/tmp/tmpiwex_o1o/input.map.txt’, ‘sample’, ‘128’, ‘t’, ‘all’, ‘/tmp/tmpiwex_o1o/output.summary.txt’]’ returned non-zero exit status 1.

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File “/home/cristian/miniconda3/envs/qiime2-2020.2/lib/python3.6/site-packages/q2cli/commands.py”, line 328, in call
results = action(**arguments)
File “</home/cristian/miniconda3/envs/qiime2-2020.2/lib/python3.6/site-packages/decorator.py:decorator-gen-477>”, line 2, in aldex2
File “/home/cristian/miniconda3/envs/qiime2-2020.2/lib/python3.6/site-packages/qiime2/sdk/action.py”, line 245, in bound_callable
output_types, provenance)
File “/home/cristian/miniconda3/envs/qiime2-2020.2/lib/python3.6/site-packages/qiime2/sdk/action.py”, line 390, in callable_executor
output_views = self._callable(**view_args)
File “/home/cristian/miniconda3/envs/qiime2-2020.2/lib/python3.6/site-packages/q2_aldex2/_method.py”, line 63, in aldex2
" and stderr to learn more." % e.returncode)
Exception: An error was encountered while running ALDEx2 in R (return code 1), please inspect stdout and stderr to learn more.

Could you give some advice to solve it??
Thank you to all!!
Cristian

Hello Cristian,

Here is the core of the error:

The ALDEx2 test only works with metadata that has exactly two groups so

Age Treatment
25 Antibiotics
75 Antibiotics
32 None
29 None

You could test Treatment (Antibiotics vs None) but you can't test Age (as it has 4 different values).

Let me know if this answers your question!

Colin

Thanks @colinbrislawn for your response!!!
I am analyzing only 3 sample metagenomic 16S sequencing, so I have only one column with the sample number in my metadata file. How can I perform a differential abundance analysis with these data?
Thanks in advance!
Cristian

Are the three samples in group? Like in my example, I has the factor: Treatment
and inside that factor there are two levels (Antibiotics and None)

What are your factors? What are your levels?

Sorry @colinbrislawn, maybe I was no clear enough, this is my first metagenomic analysis…
I have 3 sample, with no levels:
sample id sample
M-0 sample-1
M-50 sample-2
M-100 sample-3

I am interested in perform an abundance analysis comparing all samples each others. Perhaps I have a conceptual error, and this plugin is not suitable for this purpose. Could you give some advice?
Thanks!!
Cristian

Good morning Cristian,

Ah OK! So you want to perform three differential abundance tests
(Sample 1 vs 2)
(Sample 1 vs 3)
(Sample 2 vs 3)

This makes sense to me. I think the biggest issue is that differential abundance tests expect to compare groups of samples to each other, and they want more than one sample per group. You might be able to do this with ALDEx2… but I’m not sure how well that will work.

Let’s see what the developer of the ALDEx2 Qiime 2 plugin recommends!

Colin

Hi Colin,
That is exactly what I want to do! I dont know if ALDEx2 needs more than one sample per group, and if so, are there any other plugin or program that I could use?
Thanks!

1 Like

Hi @Cristian_Suarez and @colinbrislawn,
This isn’t an issue of ALDEx2 (or any other plugin for that matter) being able to handle n=1 per group or not, from a statistical perspective this just doesn’t make sense. There is no variance with n=1 to run any tests like you want. Even if for some weird reason (read: bug) a plugin can handle n=1, you shouldn’t rely on its output.

3 Likes

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.