How to combine low frequency taxa into an "other" category on barplot?

Thanks to the help I've received on the forums, I have completed my first QIIME2 workflow and produced a number of barplots, PCoAs, etc from the analysis. I am interested in publishing some barplots of order-level taxa for each group of samples, but there are many low-frequency taxa that are invisible on the plots but taking up lots of space on the legend. I'd like to merge taxa below a set relative frequency threshold (2% but maybe more) into an "other" category to clean up the visualization. Is there a way to do this in QIIME2? Thanks for the help!

Hello! I do not think that you can achieve this goal using Qiime2 standard tools (please, correct me if I am wrong). But here are some alternatives:

  1. Use Qiime2 generated barplot as it is and modify a legend (just cut it) and explain in the figure description that legend represent only top N taxa.
  2. In the barplot, if you will click on the color box in legend, it will show you only this taxa on the barplot. You can just click on the top N taxa in the legend, and everything else will be without color. Use this image and cut the legend correspondingly.
  3. Modify barplot and legend as svg files in any svg editor.
  4. Download taxa counts from the barplot as csv and plot it using R or Python.

Hi Timur, thanks for the reply. Some of the taxa are invisible in the group but when I click on them in the bar legend in QIIME2 view I see faint lines appear, so it might be hard to physically cut the graph. I think I may try to do this in R or Python, or even download the values into Prism to make easy stacked bar graphs and then I can just sum the remaining taxa into a 2% category that way.

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