9. Taxonomic Classification - DianaCarolinaVergara/16S-rRNA-Analysis GitHub Wiki

Taxonomic classification

Life is organized into nested ranks, with each higher tier representing a larger group of related organisms to which the species at the bottom belong.

Here a very interesting blog:

https://www.quantamagazine.org/phyla-and-other-flawed-taxonomic-categories-vex-biologists-20190624/

After generate the OTUs os ASVs you want to assign a taxonomic level to each one. To know to what phylum, orden, genus or species they belong.

Examples of graphics you can produce after taxonomic classification:

First, you have to select the database you're going to use. That depends on the reads you have, the primers you used, the type of seq, etc. Here I use the Greengenes database specific for V4 region and specific for Qiime 2019.7 version.

Here the code to download the greengenes gg-13-8-99-515-806-nb-classifier.qza classifier from internet.

wget \
  -O "gg-13-8-99-515-806-nb-classifier.qza" \
  "https://data.qiime2.org/2018.11/common/gg-13-8-99-515-806-nb-classifier.qza"

After import the database, you use it as an input --i-classifier, and additionally the reads generated in the dada2 step --i-reads.

And the output goes with the name taxonomy.qza after the command --o-classification

Code:

qiime feature-classifier classify-sklearn \
  --i-classifier gg-13-8-99-515-806-nb-classifier.qza \
  --i-reads rep-seqs-dada2.qza \
  --o-classification taxonomy.qza

Or if you prefer the SILVA database. Here the specific SILVA132 database specific for 16S rRNA V4 region.

qiime feature-classifier classify-sklearn \
  --i-classifier silva-132-99-515-806-nb-classifier.qza \
  --i-reads rep-seqs-dada2.qza \
  --o-classification taxonomySILVA.qza

And finally, you produce the visualization file to download and open it in the view qimme platform

https://view.qiime2.org/

qiime metadata tabulate \
  --m-input-file taxonomy.qza \
  --o-visualization taxonomy.qzv