Hi all,
I really enjoy using the artifact API to create jupyter notebooks for all my work with Qiime2.
But due to little documentation for plugin usage with the python API I need your help using the longitudinal ANOVA visualization plugin (in qiime2-2020.8)
The task is to test whether multiple effect impact alpha diversity (in this case, the pielou eveness). Let me start by saying this plugin works in the CLI version as follows:
qiime longitudinal anova
--m-metadata-file ./alpha_vector_pielou.qza
--m-metadata-file ./metadata.tsv
--p-formula 'pielou_evenness ~ Salinity * Tank'
--o-visualization ./alpha_anova_pielou.qzv
However, using the artifact API I get an error trying to supply two metadata variables:
TypeError: Parameter 'metadata' received (Metadata
--------
27 IDs x 6 columns
Sample name: ColumnProperties(type='categorical')
Group: ColumnProperties(type='categorical')
Tank: ColumnProperties(type='categorical')
Salinity: ColumnProperties(type='categorical')
Day: ColumnProperties(type='categorical')
Barcode: ColumnProperties(type='categorical')
Call to_dataframe() for a tabular representation., Metadata
--------
24 IDs x 1 column
pielou_evenness: ColumnProperties(type='numeric')
Call to_dataframe() for a tabular representation.) as an argument, which is incompatible with parameter type: Metadata
I am out of ideas how to resolve this error. If I inspect the pielou vector .qza as metadata, it reports the correct type:
pielou_alpha_vector.view(qiime2.Metadata)
Metadata
--------
24 IDs x 1 column
pielou_evenness: ColumnProperties(type='numeric')
Call to_dataframe() for a tabular representation.
Thank you very much for your feedback and for making qiime2 such a great resource.
Thank you @Nicholas_Bokulich. That worked really well. And I assume it will work in other plugins which accept multiple metadata input.
On a related note, if I can piggy back on this example, is there a description of the interpretation of results in the longitudinal ANOVA test? (maybe also related to using this test with alpha diversity metrics)
please open a new topic. New question, new Topic. This makes distinct questions easier for others to find and follow. Please also share your results (QZV) and ask a specific question, as usual, to get the best answer. Thanks
Will do. A specific example is not needed. I was just curious about the official meaning of some of the column headings in the results tables (especially to the pair-wise t-test). I can take a good guess, but I thought there would be a document that explains the output.