Hi everyone,
I am working on generating a heatmap using Qiime 2 in Virtualbox. I would like to show only data at the genus level for 6 samples. Firstly, I used qiime taxa filter-table to retain only features that were at annotated to the genus level. Then, I used ** qiime taxa collapse** to collapse features by their taxonomy at the genus level. Finally, I used ** qiime feature-table heatmap** to generate the heatmap. However, the x-axis still showing other taxa that only can annotate at order or family level. Also, in my output .qzv file, the taxa name is k_bacteria: p bacteroidetes:c sphingobacteria,o_ sphingobacteriales:f_ chitinophagaceae:g_arachidicoccus__, for example. I would like to show up the only genus name (e.g. arachidicoccus). I was wondering if qiime2 have any plugin that has this function. Below is the code I used to generate the heatmap.
qiime taxa filter-table
--i-table table.qza
--i-taxonomy customized-gg-99-taxonomy.qza
--p-include g__
--o-filtered-table table-with-genera.qza
qiime taxa collapse
--i-table table-with-genera.qza
--i-taxonomy customized-gg-99-taxonomy.qza
--p-level 6
--o-collapsed-table genera-taxanomy-table.qza
qiime feature-table heatmap
--i-table genera-taxanomy-table.qza
--m-sample-metadata-file MP_PassaicWWTP.tsv
--m-sample-metadata-column Microparticles
--p-cluster 'features'
--o-visualization customized-gg-99-genera-heatmap.qzv
This is the picture of the heatmap.
Hi!
I was searching for the same function and did not find it. But you have some options:
Download heatmap as .svg file and edit with svg editor or script. Worked not very well for me.
Export genera-taxonomy-table.qza as a biom then convert it to .tsv and edit taxa manually or with a script to show only genera, convert to biom and import it back to .qza file and then create a heatmap. Exporting, importing and converting commands can be found on this forum, but feel free to ask for it, I will provide them as soon as I will be able to reach my working PC.
Hi Timanix,
Thank you so much for your help. I will try with the second option . I would very appreciate if you could send me the commands for exporting, importing and converting.
Have a nice day.
Those taxa are actually classified at genus level, but the database annotation only consists of “g__” (i.e., unknown genus). So you are in fact getting what you are telling QIIME 2 to do — select all taxa classified at genus level.
In your qiime taxa filter-table command you could use `–p-exclude ‘f__;g__’ to exclude any classifications with unknown family and genus.
You could then use qiime taxa filter-table a second time with --p-mode exact and then indicate specific taxa that you want to exclude that are not filtered out with that first filter.