qiime2自己建立分类器 greengene

自己建立分类器

建立或获取分类器

这种方法要求事先基于参考数据库训练分类器。QIIME 2 团队建议为不同的引物组合建立专门的分类器。对于一些大家常用的引物组合,可直接在仓库中下载( http://kronos.pharmacology.dal.ca/public_files/taxa_classifiers/qiime2-2020.2_classifiers/ ),没有的话则需要自己手动建立分类器:

16S V4/V5 region (classifier_silva_132_99_16S_V4.V5_515F_926R.qza)


16S V3/V4 region (classifier_silva_132_99_16S_V3.V4_341F_805R.qza)


16S V6/V8 region (classifier_silva_132_99_16S_V6.V8_B969F_BA1406R.qza)


16S V6/V8 region targeting archaea (classifier_silva_132_99_16S_V6.V8_A956F_A1401R.qza)


16S V3/V4 region targeting cyanobacteria (classifier_silva_132_99_16S_V3.V4_CYA359F_CYA781R.qza)


18S V4 region (classifier_silva_132_99_18S_V4_E572F_E1009R.qza)


Full ITS - fungi only (classifier_sh_refs_qiime_ver8_99_s_02.02.2019_ITS.qza)


Full ITS - all eukaryotes (classifier_sh_refs_qiime_ver8_99_s_all_02.02.2019_ITS.qza)

仓库中的 SILVA 版本为 132,若想使用最新的 SILVA 138 版本可参考:https://github.com/mikerobeson/make_SILVA_db 关于如何手动根据自己的引物建立分类器请参阅:https://github.com/LangilleLab/microbiome_helper/wiki/Creating-QIIME-2-Taxonomic-Classifiers

此外,在使用这些自定义分类器时,我们应仔细检查它们在数据集上是否正确执行,手动检查分类器对 ASV 的分类尤为重要。理论上,使用特定于引物的分类器,可以改进物种注释的效果,但仍建议你在首次运行自定义 16S 分类器时同时运行全长 16S 分类器进行比较。


自己手动建立分类器代码示例: 这里以V3-V4区引物为例:

338F (5′-ACTCCTACGGGAGGCAGCAG-3′) and. 806R (5′-GGACTACHVGGGTWTCTAAT-3′)



# 下载数据库文件(greengenes)

wget -c ftp://greengenes.microbio.me/greengenes_release/gg_13_5/gg_13_8_otus.tar.gz

# 解压

tar -zxvf gg_13_8_otus.tar.gz

# 使用rep_set文件中的99_otus.fasta数据和taxonomy中的99_OTU_taxonomy.txt数据作为参考物种注释

# 导入参考序列

qiime tools import \

  --type 'FeatureData[Sequence]' \

  --input-path gg_13_8_otus/rep_set/99_otus.fasta \

  --output-path 99_otus.qza

# 导入物种分类信息

qiime tools import \

  --type 'FeatureData[Taxonomy]' \

  --input-format HeaderlessTSVTaxonomyFormat \

  --input-path gg_13_8_otus/taxonomy/99_otu_taxonomy.txt \

  --output-path ref-taxonomy.qza



# 本次使用  338F (5′-ACTCCTACGGGAGGCAGCAG-3′) and. 806R (5′-GGACTACHVGGGTWTCTAAT-3′)

#It has been shown that taxonomic classification accuracy of 16S rRNA gene sequences improves when a Naive Bayes classifier is trained on only the region of the target sequences that was sequenced (Werner et al., 2012). 

qiime feature-classifier extract-reads \

  --i-sequences 99_otus.qza \

  --p-f-primer ACTCCTACGGGAGGCAGCAG \

  --p-r-primer GGACTACHVGGGTWTCTAAT \

  --o-reads ref-seqs.qza


# Train the classifier(分类器)

# 基于筛选的指定区,生成实验特异的分类器

time qiime feature-classifier fit-classifier-naive-bayes \

  --i-reference-reads ref-seqs.qza \

  --i-reference-taxonomy ref-taxonomy.qza \

  --o-classifier classifier_gg_13_8_99_V3-V4.qza


#Classification of fungal ITS sequences

#In our experience, fungal ITS classifiers trained on the UNITE reference database do NOT benefit from extracting/trimming reads to primer sites. We recommend training UNITE classifiers on the full reference sequences. Furthermore, we recommend the “developer” sequences (located within the QIIME-compatible release download) because the standard versions of the sequences have already been trimmed to the ITS region (excluding portions of flanking rRNA genes that may be present in amplicons generated with standard ITS primers).



课程推荐:微生物扩增子分析课程实操     微生物16S/ITS/18S分析原理及结果解读


  • 发表于 2020-11-06 10:26
  • 阅读 ( 5170 )
  • 分类:宏基因组

0 条评论

请先 登录 后评论
omicsgene
omicsgene

生物信息

654 篇文章

作家榜 »

  1. omicsgene 654 文章
  2. 安生水 324 文章
  3. Daitoue 167 文章
  4. 生物女学霸 120 文章
  5. 红橙子 78 文章
  6. CORNERSTONE 72 文章
  7. rzx 66 文章
  8. xun 64 文章