宏基因组分箱(Binning)技术

导读

  • 宏基因组分箱(Binning)是将宏基因组测序得到的混合了不同生物的序列或序列组装得到的contigs按物种分开归类的过程,类似下图[1]。传统的单物种全基因组序列都是经纯培养之后,再进行全基因组de novo测序才获得的,但是环境中存在着大量的不可培养微生物,宏基因组分箱技术有助于获得不可培养微生物的全基因组序列,获得新物种的基因组序列和功能,预测未知物种的培养方法等等。


    分箱.png

一、分箱工具盘点

  • 早在2011年,science上的一篇文章就用了宏基因组Binning技术对来自牛瘤胃的样本进行了宏基因组测序研究。该研究从268 Gbp的宏基因数据中成功Binning出了15个不能培养的微生物的全基因组序列(可见分箱对数据量要求很大)。从那以后,宏基因组Binning技术开始被更多的人关注和重视,也逐渐出现了很多宏基因组Binning工具。查了一些文献和资料,我罗列了一下近几年的分箱工具,引用量仅供参考(google学术,2019.8.29)。
分箱工具 发表杂志 发表时间 引用量
ProxiMeta Genome Biology 2019 1
MetaBAT2 PeerJ 2019 4
MetaWRAP Microbiome 2018 14
DAS Tool Nature Microbiology 2018 59
Binning_refiner Bioinformatics 2017 13
COCACOLA Bioinformatics 2017 56
CoMet BMC Bioinformatics 2017 4
MetaBAT PeerJ 2015 465
MaxBin 2.0 Bioinformatics 2015 211
VizBin Microbiome 2015 110
Anvi’o PeerJ 2015 279
CONCOCT Nature Methods 2014 429
GroopM PeerJ 2014 188
MetaCluster 5.0 Bioinformatics 2012 115
PhyloPythiaS Plos One 2012 99

二、分箱工具比较

  1. 2017年Nature Methods上一篇文章对宏基因组数据处理各个过程中的软件进行了评估[ Critical Assessment of Metagenome Interpretation-a benchmark of metagenomics software ]。从文章的分析结果来看,不同的方法各有优缺(下图),MaxBin2可能是相对较好的一个分箱软件。
  • 比较结果:


    NM.png
  1. 加利福利亚大学在通过整合多个算法设计出了新的Binning软件DAS tool并在2018年发表在Nature Microbiology上 [ Recovery of genomes from metagenomes via a dereplication, aggregation and scoring strategy ]。集合了多个算法的DAS tool各项Binning指数要明显优于CONCOCT,MaxBin 2,MetaBAT等方法,比较分析结果如下:
  • 比较结果:


    对不同样本来源的宏基因组数据进行分箱完成度分析.png

    对模拟微生物群落进行基因组重建分析.png
  1. 同年,Microbiome上发表了另一个整合了多个工具的分箱分析流程MetaWRAP [MetaWRAP—a flexible pipeline for genome-resolved metagenomic data analysis. Microbiome]。
  • MetaWRAP流程不仅纳入了最流行的MetaBAT、CONCOCT和MaxBin2分箱方法,还整合了质控、拼接、分箱、提炼、评估、注释等多种功能。MetaWRAP可以解决分箱分析中可能遇到的绝大多数问题,而且比较分析发现综合多个工具的MetaWRAP分箱法不仅比单个工具分箱效果好,也比同样是综合多个算法的DAS tool分箱法效果好,比较分析结果如下:

  • 比较结果:


    完成度和污染度的比较(CAMI数据集).png

    完成度和污染度的比较(水、肠道、土壤数据).png

    metaWRAP重组装分箱效果更佳.png

三、分箱实战

  • MetaWRAP集合的算法和工具很全很多,但是也很慢,有条件的话可以自己尝试使用MetaWRAP。[Extensive Unexplored Human Microbiome Diversity Revealed by Over 150,000 Genomes from Metagenomes Spanning Age, Geography, and Lifestyle. Cell. 2019]这篇文章提到,MetaBAT2在单样本分箱中表现最佳,也在Metawrap文章中表现不错。Metawrap看似有前途,但是存在两个缺点:1)没有独立验证;2)计算成本高。考虑到时间,下面只以MetaBAT2为例简介分箱工作流程。

1. 准备

测试数据.png
  • 下载得到已经组装好的contigs文件assembly.fa和两个样本的bam文件。

2. 统计contig深度

jgi_summarize_bam_contig_depths --outputDepth depth_var.txt *.bam

  • 统计结果:


    contigs深度.png
  • 结果说明:
    第一列:contigName
    第二列:contigLen
    第三列:totalAvgDepth
    第四列:library1.sorted.bam
    第五列:library1.sorted.bam-var
    第六列:library2.sorted.bam
    第七列:library2.sorted.bam-var

3. 分箱(4线程,21秒)

time metabat2 -t 4 -i assembly.fa -a depth_var.txt -o metabat2/bin –v

  • 分箱结果:


    分箱结果.png

4. 分箱评估 (4线程,32分钟)

time checkm lineage_wf -f metabat2/checkm.txt -t 4 -x fa metabat2/ metabat2/checkm/
##  评估结果保存在checkm.txt文件中。

5. 评估结果:

  • 提取ID,Taxonomy,Completeness,Contamination信息:
grep 'bin' checkm.txt | sed 's/^  //' | awk '{print $1,$2,$13,$14}' | sed 's/\ /\t/g'| sed 's/\./\t/' | sort -n -k 2 | sed 's/\t/./' > test.txt
##  从checkm.txt提取

  • 提取结果:


    分箱评估结果.png

第一列:Bin Id
第二列:Marker lineage
第三列:Completeness
第四列:Contamination

结束语

metawrap concoct报错

/public/home/zzumgg03/huty/softwares/miniconda3/envs/metawrap-env/bin/concoct_coverage_table.py:48: FutureWarning: read_table is deprecated, use read_csv instead, passing sep='\t'.
  df = pd.read_table(fh, header=None)
Traceback (most recent call last):
  File "/public/home/zzumgg03/huty/softwares/miniconda3/envs/metawrap-env/bin/concoct_coverage_table.py", line 77, in <module>
    generate_input_table(args.bedfile, args.bamfiles, samplenames=samplenames)
  File "/public/home/zzumgg03/huty/softwares/miniconda3/envs/metawrap-env/bin/concoct_coverage_table.py", line 52, in generate_input_table
    avg_coverage_depth.to_csv(sys.stdout, index_label='contig', sep='\t', float_format='%.3f')
  File "/public/home/zzumgg03/huty/softwares/miniconda3/envs/metawrap-env/lib/python2.7/site-packages/pandas/core/generic.py", line 3007, in to_csv
    from pandas.io.formats.csvs import CSVFormatter
ImportError: cannot import name CSVFormatter

参考:

  1. 句句干货!一文读懂宏基因组binning
  2. Microbiome:宏基因组分箱流程MetaWRAP简介
  3. 宏基因组分箱Binning以及MaxBin的使用
  4. 分箱原理

\color{green}{😀😀原创文章,码字不易,转载请注明出处😀😀}

最后编辑于
©著作权归作者所有,转载或内容合作请联系作者
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

推荐阅读更多精彩内容