Table to show what's in each category

hi guys,

I have assigned my features a taxa and now looking at the tax-bar-plots.qzv
My question is where can I find the table that gives me the same data so I can export to an excel. I have 15 samples and need to see what’s on each group count wise. Also is there a way I can merge the 15 samples into 2 samples. I have tried added another column in the metadata but the chart still shows 15 groups


You can open a .qzv file as a archive and in data folder you will see .csv files by levels - just chose one of them

You can create a new metadata file but instead of sample Ids indicate a names of the groups of samples and after remove duplicates. After running the commands with a new metadata you will see the barplots for groups instead of samples.

1 Like

Hi @Rsimmonds,

I’m not sure if the recommendations here will actually work (sorry @timanix, perhaps I misunderstood your suggestion) since renaming sample-ids in the metadata file will break the connection with the existing feature-table. If you are trying to simply remove some samples from your feature-table then you can use feature-table filter-samples or if you mean to collapse your samples into 2 groups then you may want to look at feature-table group.

1 Like

@Mehrbod_Estaki, @Rsimmonds
I am apologizing I forgot to mention that first you need to group your table by some groups of samples, and then use a collapsed metadata file with group names instead of sample-IDs. First use a actual metadata to collapse a table by groups:

    qiime feature-table group \
        --i-table table.qza \
        --p-axis 'sample' \
        --m-metadata-file metadata.tsv \
        --m-metadata-column MyGroup \
        --p-mode 'mean-ceiling' \
        --o-grouped-table grouped_table.qza

Here you should create a new metadata with groups names instead sample IDs and provide a grouped table:

qiime taxa barplot \
    --i-table grouped_table.qza\
    --i-taxonomy taxonomy.qza \
    --m-metadata-file grouped_metadata.tsv \
    --o-visualization grouped_taxabar.qzv

I added another column in the metadata and added group 1 to 6samples and group 2 to 9 samples. However, when I look at the taxa plot and select by groups, they still appear in 15 seperate samples but labelled 1 and 2…i need to merge the samples

Hi @Rsimmonds,
Can you explain to us what you have done exactly up to this point? The exact code you ran would be useful.
Did you follow the instructions regarding collapsing your feature-table using feature-table group first? If you are seeing all 15 samples then that to me means that your table still has 15 separate samples instead of 2 <- not grouped. Just adding an extra column in the metadata file is not going to collapse the groups.

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