Exporting alpha diversity results into R

I think this is a specific situation relating to this question. In my lab we would usually get our alpha diversity metrics from qiime 1 and use the outputted text file in R. This allowed us to check for the normality of the data. We could then normalize the data (or not) and use the statistics of our choice to compare the alpha diversity of our different communities. Would my only option right now, in order to in order keep using this approach, be to export the feature table and then run alpha diversity metrics in qiime1? I don’t want to have to extract the underlying data from each of my .qza alpha diversity files (shannon, faith’s PD, evenness and observed otus) into a biom file, merge and then convert to a txt file. Thanks!

Hi @pjtorres!

Yes, you can export your feature table with qiime tools export and perform further analyses in R or QIIME 1 with the .biom file. You can also import your data back into QIIME 2 at any step, as long as the file format is supported by QIIME 2.

Instead of exporting your feature table, you could export your alpha diversity results using qiime tools export and import that TSV file into R or QIIME 1 to perform normality checks and other diversity analyses.

To obtain a single TSV file with collated alpha diversity metrics, unfortunately you'll need to export each SampleData[AlphaDiversity] .qza file and combine those TSV files manually (for example, using Excel). We may have future support in QIIME 2 for combining these files and exporting them but for now it's a bit of a manual process. We're tracking this feature on the issue tracker here.

I'm not sure what you mean by "extract the underlying [alpha diversity] data [...] into a biom file, merge and then convert to a txt file". If you're wanting to import the collated alpha diversity results into R, you can create a TSV file directly from your alpha diversity results and shouldn't need to create a .biom file, merge (?), and convert into a .txt file. If that doesn't answer your question or make sense, can you please describe your workflow in a little more detail?

4 Likes

You answered my question @jairideout. I appreciate the quick and clear response . Thanks!

2 Likes

This has been resolved in QIIME 2 2017.6! :tada:

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