Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

import qiime2 output files .qza or .qzv #830

Closed
hshcao opened this issue Oct 11, 2017 · 8 comments
Closed

import qiime2 output files .qza or .qzv #830

hshcao opened this issue Oct 11, 2017 · 8 comments

Comments

@hshcao
Copy link

hshcao commented Oct 11, 2017

No description provided.

@hshcao
Copy link
Author

hshcao commented Oct 11, 2017

can phyloseq take qiime2 output types such as .qza or .qzv?
Thanks,

HC

@hshcao hshcao changed the title import qiime2 import qiime2 output files .qza or .qzv Oct 11, 2017
@colinbrislawn
Copy link

Not yet. However, you can use qiime2 to export your data as a .biom table, then import that into phyloseq.

@joey711
Copy link
Owner

joey711 commented Nov 6, 2017

I recommend @colinbrislawn suggestion, to use an open standard file format like .biom that is already supported in phyloseq.

I don't have plans to try to support another QIIME-specific file format, which they had previously indicated they were going to stop producing and migrate to biom-format. In many respects, you might want to consider .qza to be a QIIME-specific format, and not use it to transmit data to external software. By that same philosophy, you are probably better off publishing data as biom-format.

@joey711 joey711 closed this as completed Nov 6, 2017
@colinbrislawn
Copy link

consider .qza to be a QIIME-specific format

This is correct. Note that .qza captures not only the OTU table and tax table, it also captures the providence of those tables including any filtering or normalization that has been done. When using R and phyloseq, you would capture these processing steps using an R Markdown File or a Jupyter notebook.

@nachishankar
Copy link

nachishankar commented Mar 2, 2018

What is the .qza format? Is there any way to visualize this file type? What does it contain?

@gregcaporaso
Copy link

you might want to consider .qza to be a QIIME-specific format

That's fair, but note that qza and qzv are literally just zip files with a defined internal directory structure so it's very easy to get data out in the "usual" formats. For example:

# download the feature table from the moving pictures tutorial
$ wget https://docs.qiime2.org/2018.2/data/tutorials/moving-pictures/table.qza

# unzip that file with the macOS unzip utility - QIIME is not needed for this
$ unzip table.qza
Archive:  table.qza
  inflating: dae3fb70-4eb6-4ed2-a1e9-9f9ede0f7d43/metadata.yaml
  inflating: dae3fb70-4eb6-4ed2-a1e9-9f9ede0f7d43/VERSION
  inflating: dae3fb70-4eb6-4ed2-a1e9-9f9ede0f7d43/provenance/metadata.yaml
  inflating: dae3fb70-4eb6-4ed2-a1e9-9f9ede0f7d43/provenance/VERSION
  inflating: dae3fb70-4eb6-4ed2-a1e9-9f9ede0f7d43/provenance/artifacts/3c118cb6-43ea-4f22-aa53-18086b87b1f9/metadata.yaml
  inflating: dae3fb70-4eb6-4ed2-a1e9-9f9ede0f7d43/provenance/artifacts/3c118cb6-43ea-4f22-aa53-18086b87b1f9/VERSION
  inflating: dae3fb70-4eb6-4ed2-a1e9-9f9ede0f7d43/provenance/artifacts/3c118cb6-43ea-4f22-aa53-18086b87b1f9/action/action.yaml
  inflating: dae3fb70-4eb6-4ed2-a1e9-9f9ede0f7d43/provenance/artifacts/0ee3839e-b7e7-4aa5-a4fd-9c2070d77209/metadata.yaml
  inflating: dae3fb70-4eb6-4ed2-a1e9-9f9ede0f7d43/provenance/artifacts/0ee3839e-b7e7-4aa5-a4fd-9c2070d77209/VERSION
  inflating: dae3fb70-4eb6-4ed2-a1e9-9f9ede0f7d43/provenance/artifacts/0ee3839e-b7e7-4aa5-a4fd-9c2070d77209/action/action.yaml
  inflating: dae3fb70-4eb6-4ed2-a1e9-9f9ede0f7d43/provenance/artifacts/0ee3839e-b7e7-4aa5-a4fd-9c2070d77209/action/barcodes.tsv
  inflating: dae3fb70-4eb6-4ed2-a1e9-9f9ede0f7d43/provenance/action/action.yaml
  inflating: dae3fb70-4eb6-4ed2-a1e9-9f9ede0f7d43/data/feature-table.biom

# notice the last entry in that list is the .biom file

# call biom head - QIIME is also not needed for this, but biom is
$ biom head -i dae3fb70-4eb6-4ed2-a1e9-9f9ede0f7d43/data/feature-table.biom
# Constructed from biom file
#OTU ID	L1S105	L1S140	L1S208	L1S257	L1S281
4b5eeb300368260019c1fbc7a3c718fc	2222.0	0.0	0.0	0.0	0.0
fe30ff0f71a38a39cf1717ec2be3a2fc	5.0	0.0	0.0	0.0	0.0
d29fe3c70564fc0f69f2c03e0d1e5561	0.0	0.0	0.0	0.0	0.0
868528ca947bc57b69ffdf83e6b73bae	0.0	2276.0	2156.0	1205.0	1772.0
154709e160e8cada6bfb21115acc80f5	812.0	1176.0	713.0	407.0	242.0

What is the .qza format? Is there any way to visualize this file type? What does it contain?

It's a zip file. The data/ directory contains your data in the "typical" format (biom, fasta, newick, ...). Everything else in the zip file is QIIME2-specific metadata that you can safely ignore. You can open this with any unzip utility. qza files are QIIME Zipped Artifacts - these represent intermediate outputs that are not intended for human consumption. qzv files are QIIME Zipped Visualizations - these represent terminal outputs that are intended for human consumption.

Our developer documentation is a work in progress at the moment, but you can see some information here that more fully defines the structure of these qza/qzv (i.e., zip) files.

If you want to see why we bother with all of this, you can view the files in way that makes use of the QIIME-specific metadata (no QIIME installation required). You can drag and drop and .qza/.qzv file to https://view.qiime2.org - note that .qzv files are inherently more interesting to view than .qza files. Here's a link that will open a .qzv summary of the table I worked with above. While you're at https://view.qiime2.org, click over to the Provenance tab, to see some of the value added by the qza/qzv approach. That tab provides detailed information on all of the QIIME steps that were performed to generate that .qza file, including versions of all QIIME 2 software and dependencies, parameters used at each analysis step, ... (click through the circles and squares in the graph).

you are probably better off publishing data as biom-format.

I argue that it is more useful to publish data in qza/qzv than in biom format directly (you can change the extension to .zip first to make it more clear to people accessing that data), as (1) it contains information on where the table came from without having to rely on that being correctly and comprehensively reported in the corresponding paper, and (2) the biom-formatted file can always just be accessed by unzipping. But I may be slightly biased...

@nasden
Copy link

nasden commented Dec 17, 2018

Not yet. However, you can use qiime2 to export your data as a .biom table, then import that into phyloseq.

How?

@colinbrislawn
Copy link

you can use qiime2 to export your data as a .biom table

How?

Try this: https://docs.qiime2.org/2018.11/tutorials/exporting/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants