macでインフォマティクス

macでインフォマティクス

HTS (NGS) 関連のインフォマティクス情報についてまとめています。

ロングリードを使ってMobile elements挿入を検出する rMETL

2019 2/19 流れ修正 

 

 Mobile element insertion(MEI)は、ヒトゲノムにおける構造変化(SV)の約25%に相当し、これは主にAlu、L1およびSVAファミリーなどのアクティブなmobile elementsによってもたらされる(Stewart et al、2011)。これまでショートリードでMEIを検出するための努力がなされてきた(Gardner et al、2017)が、ショートリードベースのアプローチでは、反復性の高いmobile elementsを扱うときに制限が生じる可能性がある。
 ロングリードは、リピートを処理しそしてSVを発見するより優れた能力を実証した(Sedlazeck et al、2018a)。ただし、mobile elementsの反復性と重大なシーケンスエラーの両方を考慮すると、ロングリードによって暗示されるMEIの信号は非常に複雑になる(補足に詳細な説明あり)。最先端のロングリードベースのSV検出手法(Sedlazeck  et ak、2018b, link)は、様々な種類のSVを検出するために統一されたアプローチを使用する。この「万能の」戦略では、複雑な信号をうまく処理するためにMEIの特性を十分に考慮できない可能性がある。
 ここでは、Realignment-based Mobile Element insertion detection Tool for Long read(rMETL)を提案する。 rMETLは、特別に設計されたキメラリードリアライメントアプローチを利用して、MEI signalsをうまく処理し、false callを除きながらMEIを検出する。ベンチマーク結果は、rMETLが高品質のcallセットを生成できることを示している。

  rMETLは、Pacific Biosciences(PacBio)やOxford Nanopore Technologyなどの主流のプラットフォームで生成されたリードをサポートしている。 ソートされたBAMファイルを入力として使用して、rMETLは、以下の4ステップでMEIを発見する。

  1. 入力ファイルからキメラリード(スプリットアライメント、ラージクリッピングまたはラージindelを有するリード)を抽出する(補足図2)。
  2. キメラアライメントされたリードの部分を一連の特別に設計された規則でクラスタ化し、一連のMEIサイトを推論する。
  3. よく調整されたリードアラインメントアプローチを用いて、クラスター化されたリード部分をAlu、L1およびSVAファミリーのコンセンサス配列にリアライメントする。
  4. リアライメント結果を調べ、false signalをフィルタリングしながら証拠を見つける。

詳細については、論文補足説明を参照。

 

インストール

ubuntu16.04のminiconda2.4.0.5環境でテストした。

依存

Current version of rMETL needs to be run on Linux operating system.

Python version 2.7

1. pysam
2. Biopython
3. ngmlr
4. samtools
5. cigar

本体 Github

git clone https://github.com/hitbc/rMETL.git
cd rMETL/

#Use the bash command for generating the executable file
bash INSTALL.sh
./rMETL.py

>./rMETL.py -h

$ ./rMETL.py -h

usage: rMETL.py [-h] STAGE ...

 

           _  ___  _   _____   _______   _

     _ _  | ^_   _^ | |  ___| |__   __| | |

    | ^_| | | | | | | | |__      | |    | |

    | |   | | | | | | |  __|     | |    | |

    | |   | | | | | | | |___     | |    | |___

    |_|   |_| |_| |_| |_____|    |_|    |_____|

 

    rMETL - realignment-based Mobile Element insertion detection Tool for Long read

 

  STAGE is one of

    detection    Inference of putative MEI loci.

    realignment  Realignment of chimeric read parts.

    calling      Mobile Element Insertion calling.

    

  See README.md for documentation or --help for details

  

  rMETL V1.0.2

  Author: Jiang Tao

  Contact: tjiang@hit.edu.cn

 

positional arguments:

  STAGE       Stage to execute

  OPTIONS     Options to pass to the stage

 

optional arguments:

  -h, --help  show this help message and exit

> ./rMETL.py detection -h

$ ./rMETL.py detection -h

usage: rMETL.py detection [-h] [-s MIN_SUPPORT] [-l MIN_LENGTH]

                          [-d MIN_DISTANCE] [-t THREADS] [-x PRESETS]

                          [SAM,BAM,FASTA,FASTQ] REFERENCE temp_dir output

 

           _  ___  _   _____   _______   _

     _ _  | ^_   _^ | |  ___| |__   __| | |

    | ^_| | | | | | | | |__      | |    | |

    | |   | | | | | | |  __|     | |    | |

    | |   | | | | | | | |___     | |    | |___

    |_|   |_| |_| |_| |_____|    |_|    |_____|

 

    rMETL - realignment-based Mobile Element insertion detection Tool for Long read

 

Map reads using NGMLR and Samtools to produce .bam file.

 

If input is a .fastq, or .fasta, we do the initial mapping

for you all at once.

 

If input is a .sam, we convert and sort it to be a bam, 

and then make an index for it.  

 

If your input is a .bam, we extract the ME signatures and

collect the sub-sequence of them.

 

The output is a .fasta file contains potentials non-reference

ME clusters.

 

rMETL V1.0.2

Author: Jiang Tao

Contact: tjiang@hit.edu.cn

 

positional arguments:

  [SAM,BAM,FASTA,FASTQ]

                        Input [Mapped/Unmapped] reads.

  REFERENCE             The reference genome (fasta format).

  temp_dir              Temporary directory to use for distributed jobs.

  output                Directory to output potential ME loci.

 

optional arguments:

  -h, --help            show this help message and exit

  -s MIN_SUPPORT, --min_support MIN_SUPPORT

                        Mininum number of reads that support a ME.[5]

  -l MIN_LENGTH, --min_length MIN_LENGTH

                        Mininum length of ME to be reported.[50]

  -d MIN_DISTANCE, --min_distance MIN_DISTANCE

                        Mininum distance of two ME clusters to be

                        intergrated.[20]

  -t THREADS, --threads THREADS

                        Number of threads to use.[8]

  -x PRESETS, --presets PRESETS

                        The sequencing platform <pacbio,ont> of the

                        reads.[pacbio]

kazu@edb2e2639563:~/rMETL$ 

./rMETL.py realignment -h

$ ./rMETL.py realignment -h

usage: rMETL.py realignment [-h] [-t THREADS] [-x PRESETS]

                            [--subread_length SUBREAD_LENGTH]

                            [--subread_corridor SUBREAD_CORRIDOR]

                            FASTA ME_Ref output

 

           _  ___  _   _____   _______   _

     _ _  | ^_   _^ | |  ___| |__   __| | |

    | ^_| | | | | | | | |__      | |    | |

    | |   | | | | | | |  __|     | |    | |

    | |   | | | | | | | |___     | |    | |___

    |_|   |_| |_| |_| |_____|    |_|    |_____|

 

    rMETL - realignment-based Mobile Element insertion detection Tool for Long read

 

Realignment of chimeric read parts.

 

Aligner: NGMLR version 0.2.6

TE refs: Alu concensus

L1 concensus

SVA concensus

The output of this script is a .sam file.

 

rMETL V1.0.2

Author: Jiang Tao

Contact: tjiang@hit.edu.cn

 

positional arguments:

  FASTA                 Input potential_ME.fa.

  ME_Ref                The reference genome(fasta format).

  output                Prefix of potential ME classification.

 

optional arguments:

  -h, --help            show this help message and exit

  -t THREADS, --threads THREADS

                        Number of threads to use.[8]

  -x PRESETS, --presets PRESETS

                        The sequencing platform <pacbio,ont> of the

                        reads.[pacbio]

  --subread_length SUBREAD_LENGTH

                        Length of fragments reads are split into [128]

  --subread_corridor SUBREAD_CORRIDOR

                        Length of corridor sub-reads are aligned with [20]

kazu@edb2e2639563:~/rMETL$ 

./rMETL.py calling -h

$ ./rMETL.py calling -h

usage: rMETL.py calling [-h] [-hom HOMOZYGOUS] [-het HETEROZYGOUS]

                        [-q MIN_MAPQ] [-c CLIPPING_THRESHOLD]

                        [--sample SAMPLE] [--MEI MEI]

                        SAM REFERENCE [BED,VCF] output

 

           _  ___  _   _____   _______   _

     _ _  | ^_   _^ | |  ___| |__   __| | |

    | ^_| | | | | | | | |__      | |    | |

    | |   | | | | | | |  __|     | |    | |

    | |   | | | | | | | |___     | |    | |___

    |_|   |_| |_| |_| |_____|    |_|    |_____|

 

    rMETL - realignment-based Mobile Element insertion detection Tool for Long read

 

rMETL MEI calling.

 

Optional output format: .bed or .vcf

 

rMETL V1.0.2

Author: Jiang Tao

Contact: tjiang@hit.edu.cn

 

positional arguments:

  SAM                   Input cluster.sam.

  REFERENCE             The reference genome(fasta format).

  [BED,VCF]             The format of the output file. [bed]

  output                Prefix of final call set.

 

optional arguments:

  -h, --help            show this help message and exit

  -hom HOMOZYGOUS, --homozygous HOMOZYGOUS

                        The mininum score of a genotyping reported as a

                        homozygous.[0.8]

  -het HETEROZYGOUS, --heterozygous HETEROZYGOUS

                        The mininum score of a genotyping reported as a

                        heterozygous.[0.3]

  -q MIN_MAPQ, --min_mapq MIN_MAPQ

                        Mininum mapping quality.[20]

  -c CLIPPING_THRESHOLD, --clipping_threshold CLIPPING_THRESHOLD

                        Mininum threshold of realignment clipping.[0.5]

  --sample SAMPLE       The name of the sample that is noted.

  --MEI MEI             Enables rMETL to display MEI/MED only.[True]

kazu@edb2e2639563:~/rMETL$ 

 

 

実行方法

1、推定MEI検出。マッピングして得たbamファイルを指定する。

mkdir temp
mkdir output
rMETL.py detection input.bam reference.fa temp/ output

 output/ にpotential_ME.faが出力される。

 

2、キメラリード部分のリアライメント

rMETL.py realignment output/potential_ME.fa reference.fa output

 outputcluster.samが出力される。

 

3、MEIのcall

rMETL.py calling output/cluster.sam reference.fa <out_type>  output

 

引用

rMETL: sensitive mobile element insertion detection with long read realignment
Tao Jiang Bo Liu Junyi Li Yadong Wang

Bioinformatics, Published: 13 February 2019

 

関連