I am currently trying to filter select taxa (e.g., archaea) from my table, and I am running into the following error:
"Plugin error from taxa:
CategoricalMetadataColumn does not support values with leading or trailing whitespace characters. Column ‘Taxon’ has the following value: 'D_0__Bacteria;D_1__Armatimonadetes;D_2__uncultured;D_3__uncultured bacterium '"
From reading the previous forums, its advised to either delete whitespaces manually [this did not work] or using a transformer https://github.com/qiime2/q2-types/issues/179 should work. How would one go about using the transformer?
This is really the only way forward at the moment — if it “didn’t work,” that indicates that you didn’t actually delete the trailing whitespace. Can you provide us with some concrete commands or actions you performed?
I think there might be a misunderstanding here, you are already using those transformers when you are filtering your table (the transformer is invoked automatically). The issue linked above was proposing amending those transformers to strip the whitespace, but, that hasn’t happened yet.
To delete the whitespaces, I exported “silva-132-99-taxonomy.qza” and opened the file in Sublime. Using the search function, I proceeded to delete all whitespaces. [If these are different than ‘normal’ spaces, then I did it wrong.]
My commands in q2, however, were:
qiime taxa filter-table
–i-table [Table post-pairing, -QC, -deblur]
–i-taxonomy silva-132-99-taxonomy.qza
–p-include 0__Bacteria
–p-mode contains
–output-dir [Table post-pairing, -QC, -deblur, -NoArchaea]
OH! well, that is great, then… because I was utterly confused. Until that amendment is integrated, is there a custom command or script that has been developed to combat this issue?
Then after “qiime feature-classifier fit-classifier-naive-bayes,” you’ll need to run “qiime feature-classifier classify-sklearn” with:
–p-confidence -1
–p-read-orientation same