quarTeT: Telomere-To-Telomere Toolkit

quarTeT is a collection of tools designed for T2T genome assembly and automated genomic analyses.

The toolkit includes four main modules:

Getting started

Dependencies

  • Python3 (>3.6, tested on 3.7.4 and 3.9.12)
  • Minimap2 (tested on 2.24-r1122 and 2.24-r1155-dirty)
  • (Optional)Unimap (tested on 0.1-r41)
  • MUMmer4 (tested on 4.0.0rc1)
  • trf (tested on 4.09)
  • CD-hit (tested on 4.6 and 4.8.1)
  • BLAST+ (tested on 2.8.1 and 2.11.0)
  • tidk (tested on 0.2.1 and 0.2.31)
  • gnuplot (tested on 4.6 and 5.4)
  • R (>3.5.0, tested on 3.6.0 and 4.2.2)
    • RIdeogram (tested on 0.2.2)
    • ggplot2 (tested on 3.3.6 and 3.4.4)

All these dependencies can be easily install via conda:

conda create -n quartet --channel conda-forge --channel bioconda python minimap2 mummer4 trf cd-hit blast tidk r r-rideogram r-ggplot2 gnuplot unimap

Installation

  1. Download quarTeT from Here, or visit the GitHub repository.
  2. Extract the archive: tar -xf quartet-v1.3.1.tar.gz
  3. Enter the directory: cd quartet-v1.3.1
  4. Run the following command to start: pip install . --no-deps --ignore-installed

Alternative installation methods

Conda

conda install --channel conda-forge --channel bioconda quartet-bio
mamba install --channel conda-forge --channel bioconda quartet-bio

Docker

docker pull quay.io/biocontainers/quartet-bio:<version>--<hash>

Singularity

singularity pull docker://quay.io/biocontainers/quartet-bio:<version>--<hash>

Note: Replace <version>--<hash> with the actual version tag. Check the Quay.io repository for available tags.

Usage

quarTeT: Telomere-to-telomere Toolkit

Usage: quartet <module> <parameters>

Modules:

AssemblyMapper| amAssemble draft genome.
GapFiller| gfFill gaps in draft genome.
TeloExplorer| teIdentify telomeres.
CentroMiner| cmIdentify centromere candidates.

Use <module> -h for module usage.

AssemblyMapper

AssemblyMapper is a reference-guided assemble tool.

A phased contig-level assembly and a close-related reference genome are required as input, both in fasta format.

Note that contigs should be phased.

It's recommended to obtain such an assembly using hifiasm.

You can convert {prefix}.bp.hap1.p_ctg.gfa and {prefix}.bp.hap2.p_ctg.gfa generated by hifiasm to FASTA format as input, separately.

Usage: quartet AssemblyMapper <parameters>

-h, --helpshow this help message and exit
-r REFERENCE_GENOME(*Required) Reference genome file, FASTA format.
-q CONTIGS(*Required) phased contigs file, FASTA format.
-c MIN_CONTIG_LENGTHContigs shorter than INT (bp) will be removed, default: 50000
-l MIN_ALIGNMENT_LENGTHThe min alignment length to be select (bp), default: 10000
-i MIN_ALIGNMENT_IDENTITYThe min alignment identity to be select (%), default: 90
-p PREFIXThe prefix used on generated files, default: quarTeT
-t THREADSUse number of threads, default: 1
-a {minimap2,unimap,mummer}Specify alignment program (support minimap2, unimap and mummer), default: minimap2
--nofilterUse original sequence input, no filtering.
--keepKeep the unplaced contigs in draft genome
--groupcontigAdd an folder output of contigs grouped by destination.
--extract-ref-flanks CHIMERAAdd an output of chimera contig containing reference flanks of x bp (check issue#42 for detail), default: 0 (off)
--plotPlot a colinearity graph for draft genome to reference alignments. (will cost more time)
--noplotSkip all ploting.
--overwriteOverwrite existing alignment file instead of reuse.
--minimapoption MINIMAPOPTIONPass additional parameters to minimap2 program, default: -x asm5
--nucmeroption NUCMEROPTIONPass additional parameters to nucmer program.
--deltafilteroption DELTAFILTEROPTIONPass additional parameters to delta-filter program.
--teclade {plant,animal,other}Specify clade of this genome for telomere search. Plant will search TTTAGGG, animal will search TTAGGG, other will use tidk explore's suggestion, default: other
--teminrepeattimes TE_MIN_REPEAT_TIMESThe min repeat times to considered as telomere, default: 100
--noteloSkip telomere-assisted ordering and orientation.

Output files should be as follow:

{prefix}.draftgenome.fasta| The pseudo-chromosome-level assembly, fasta format.
{prefix}.draftgenome.agp| The structure of this assembly, AGP format.
{prefix}.draftgenome.stat| The statistic of this assembly, including total size and each chromosome's size, GC content, gap count and locations.
{prefix}.draftgenome.png/svg| The figure draws relative length of chromosomes and gap locations for assembly.
{prefix}.contig.mapinfo| The statistic of input contigs, including total mapped and discarded size, and each contig's destination.
{prefix}.contig_map_ref.png| The alignment colinearity graph between contigs and reference genome.

Optional output:

{prefix}.draftgenome_map_ref.png| The alignment colinearity graph between this assembly genome and reference genome. Only available with --plot.
{prefix}.chimera_contig.fasta| Chimera contig containing reference flanks of x bp (check issue#42 for detail). Only available with --extract-ref-flanks.
{prefix}.groupcontig (Folder)| Contigs grouped by reference chromosome per fie. Only available with --groupcontig.

GapFiller

GapFiller is a long-reads based gapfilling tool.

A gap-tied genome and corresponding long-reads are required as input, both in fasta format.

If possible, using long-reads assembled and polished contigs instead of reads may improve the quality.

GapFiller support two mode: fill and join. fill means find a segment that can be placed in the gap and link them together. join means find an evidence that the gap edge is overlaped and can be directly merged into one. For now, join mode is unstable and disabled by default. If you want to enable it, be careful and check the result manually.

Usage: quartet GapFiller <parameters>

-h, --helpshow this help message and exit
-d DRAFT_GENOME(*Required) Draft genome file to be filled, FASTA format.
-g GAPCLOSER_CONTIG [GAPCLOSER_CONTIG ...](*Required) All contigs files (accept multiple file) used to fill gaps, FASTA format.
-f FLANKING_LENThe flanking seq length of gap used to anchor (bp), default: 5000
-l MIN_ALIGNMENT_LENGTHThe min alignment length to be select (bp), default: 1000
-i MIN_ALIGNMENT_IDENTITYThe min alignment identity to be select (%), default: 40
-m MAX_FILLING_LENThe max sequence length acceptable to fill any gaps, default: 1000000
-a {minimap2,unimap}Specify alignment program (support minimap2 and unimap), default: minimap2
-p PREFIXThe prefix used on generated files, default: quarTeT
-t THREADSUse number of threads, default: 1
--enablejoinEnable join mode to close the gaps. (Unstable)
--joinonlyUse only join mode without fill, should be used with --enablejoin.
--join-min-overlap JOIN_MIN_OVERLAPThe min overlap length required for join on draft genome components (bp), default: 50
--join-min-identity JOIN_MIN_IDENTITYThe min overlap identity required for join on draft genome components (%), default: 30
--overwriteOverwrite existing alignment file instead of reuse.
--minimapoption MINIMAPOPTIONPass additional parameters to minimap2 program, default: -x asm5
--noplotSkip all ploting.

Output files should be as follow:

{prefix}.genome.filled.fasta| The gap-filled genome, fasta format.
{prefix}.genome.filled.modified.agp| The modified chromosome structure, AGP format.
{prefix}.genome.filled.detail| Detailed information for each gap, including gap closed and remains, total filled size and closer's ID, range, etc.
{prefix}.genome.filled.stat| The statistic of filled genome, including total size and each chromosome's size, GC content, gap count and locations.
{prefix}.genome.filled.png/svg| The figure draws relative length of chromosomes and gap locations for assembly.

TeloExplorer

TeloExplorer is a telomere identification tool.

A genome file in fasta format is required as input.

Usage: quartet TeloExplorer <parameters>

-h, --helpshow this help message and exit
-i GENOME(*Required) Genome file to be identified, FASTA format.
-c {plant,animal,other}Specify clade of this genome. Plant will search TTTAGGG, animal will search TTAGGG, other will use tidk explore's suggestion, default: other
-m MIN_REPEAT_TIMESThe min repeat times to be reported, default: 100
-p PREFIXThe prefix used on generated files, default: quarTeT
--noplotSkip all ploting.

Output files should be as follow:

{prefix}.telo.info| The statistic of telomere, including monomer, repeat times on both end of each chromosome.
{prefix}.telo.png/svg| The figure draws telomere location, alongside relative length of chromosomes and gap locations for assembly.

CentroMiner

CentroMiner is a centromere prediction tool.

A genome file in fasta format is required as input.

Optionally, an addition input of TE annotation (or just LTR annotation) in gff3 format can improve the performance.

It's recommended to obtain TE annotation using EDTA.

{genome file}.mod.EDTA.TEanno.gff3 generated by EDTA can directly feed CentroMiner, unless you have sequence ID longer than 15 characters.

Note that the sequence ID in first column should be consistent with in genome. Some tools may change sequence ID if ID is too long.

The sequence ontology in the third column should include LTR or long_terminal_repeat (EDTA default), or have LTR in the eighth column (RepeatMasker default) to be recognized.

Usage: quartet CentroMiner <parameters>

-h, --helpshow this help message and exit
-i GENOME_FASTA(*Required) Genome file, FASTA format.
--TE TETE annotation file, gff3 format.
-n MIN_PERIODMin period to be consider as centromere repeat monomer. Default: 100
-m MAX_PERIODMax period to be consider as centromere repeat monomer. Default: 200
-s CLUSTER_IDENTITYMin identity between TR monomers to be clustered (Cannot be smaller than 0.8). Default: 0.8
-d CLUSTER_MAX_DELTAMax period delta for TR monomers in a cluster. Default: 10
-e EVALUEE-value threholds in blast. Default: 0.00001
-g MAX_GAPMax allowed gap size between two tandem repeats to be considered as in one tandem repeat region. Default: 50000
-l MIN_LENGTHMin size of tandem repeat region to be selected as candidate. Default: 100000
-t THREADSLimit number of using threads, default: 1
-p PREFIXPrefix used by generated files. Default: quarTeT
--trf [TRF_PARAMETER ...]Change TRF parameters: <match> <mismatch> <delta> <PM> <PI> <minscore> Default: 2 7 7 80 10 50
-r MAX_TR_LENGTHMaximum TR length (in millions) expected for trf. Default: 3
--overwriteOverwrite existing trf dat file instead of reuse.
--noplotSkip all ploting.

Output files should be as follow:

Candidates/| The folder of all centromere candidates data on each chromosome. Check the pdf line chart and vote a best candidate.
TandemRepeat/| The folder of all tandem repeat monomers identified by trf and cluster result on each chromosome.