Error filtering taxa

Hi,

I am currently trying to filter specific taxa from my feature table. I have searched the forum and have found some information that has been helpful, but hasn't completely solved my issue. Currently, I want to eliminate the unassigned taxa as well as taxa that does not provide information at phylum level (k__Bacteria;__ and k__Bacteria;p__).

I have been trying to use the filtering command as follows:

qiime taxa filter-table --i-table feature-table.qza --i-taxonomy taxonomy-Feb-2025.qza --p-exclude Unassigned --p-include p__ --o-filtered-table 16S-no-sings-filtered-table.qza

However, if I use the --p-include p__ parameter, the taxa k__Bacteria;p__ is not eliminated. I have tried several ways, but can seem to find a correct way to eliminate them.

I appreciate any help!

1 Like

Hi @natalie.melendez !

Does using --p-exclude p__; solve the issue?

Best,

Sergio

3 Likes

Hi @natalie.melendez,

I think its the structure of your query. The trick I use when I want to keep a level is to ask for the new lower level.

So include ";c__" should get me anything with at least a class in the string. When you collapse your data, that class information is hidden, but you only have taxa that have a string.

Edit: I love two different solutions to the same problem!

Best,
Justine

4 Likes

Hi @salias and @jwdebelius!

Thank you so much for your help! I was able to solve the issue with your recommendations.

Best,

Natalie

2 Likes