WTDBG2(1)

WTDBG2 ๐Ÿ’– the de novo sequence assembler page, bestie edition

okay so you found wtdbg2(1) โ€” the User Commands girlie herself. sit down, grab a strawberry, we're doing this ๐Ÿ’…


โœจ NAME โœจ

wtdbg2 โ€” de novo sequence assembler for long noisy reads. that's the whole vibe. it takes your long, messy, noisy reads and makes a genome out of them. iconic behavior honestly ๐Ÿงฌโœจ


๐ŸŒธ SYNOPSIS ๐ŸŒธ

wtdbg2 [options] -i <reads.fa> -o <prefix> [reads.fa ...]

๐Ÿ’œ DESCRIPTION ๐Ÿ’œ

WTDBG: de novo assembler for long noisy sequences.

  • Author: Jue Ruan <ruanjue@gmail.com> ๐Ÿซถ
  • Version: 2.5 (20190621)

no cap, that's the whole intro. the author ate and left no crumbs.


๐ŸŽ€ OPTIONS ๐ŸŽ€

the main character flags

  • -i <string> โ€” Long reads sequences file (REQUIRED; can be multiple), []. you literally cannot run without this one bestie.
  • -o <string> โ€” Prefix of output files (REQUIRED), []. also mandatory, no exceptions ๐Ÿ’€
  • -t <int> โ€” Number of threads, 0 for all cores, [4]. throw more cores at it, she's hungry.
  • -f โ€” Force to overwrite output files. it's giving "i don't care, just do it" โœจ
  • -x <string> โ€” Presets, comma delimited, [].

the preset lore, listen closely:

  • preset1 / rsII / rs: -p 21 -S 4 -s 0.05 -L 5000
  • preset2: -p 0 -k 15 -AS 2 -s 0.05 -L 5000
  • preset3: -p 19 -AS 2 -s 0.05 -L 5000
  • sequel / sq
  • nanopore / ont:
    • (genome size < 1G: preset2) -p 0 -k 15 -AS 2 -s 0.05 -L 5000
    • (genome size >= 1G: preset3) -p 19 -AS 2 -s 0.05 -L 5000
  • preset4 / corrected / ccs: -p 21 -k 0 -AS 4 -K 0.05 -s 0.5
  • -g <number> โ€” Approximate genome size (k/m/g suffix allowed) [0]. just tell her how big the genome is, she'll handle it ๐Ÿฆ‹
  • -X <float> โ€” Choose the best <float> depth from input reads (effective with -g) [50.0]. depth-maxxing, lowkey.
  • -L <int> โ€” Choose the longest subread and drop reads shorter than <int> (5000 recommended for PacBio) [0]. Negative integer indicate tidying read names too, e.g. -5000. so negative = rename glow-up too, slay.
  • -k <int> โ€” Kmer fsize, 0 <= k <= 23, [0]
  • -p <int> โ€” Kmer psize, 0 <= p <= 23, [21]. k + p <= 25, seed is <k-mer>+<p-homopolymer-compressed> ๐Ÿ”ฅ
  • -K <float> โ€” Filter high frequency kmers, maybe repetitive, [1000.05]. condition: >= 1000 and indexing >= (1 - 0.05) * total_kmers_count
  • -S <float> โ€” Subsampling kmers, 1/(<-S>) kmers are indexed, [4.00]. -S is very useful in saving memory and speeding up โ€” please note that subsampling kmers will have less matched length. the way that memory stays cute ๐Ÿ˜Œ
  • -l <float> โ€” Min length of alignment, [2048]
  • -m <float> โ€” Min matched length by kmer matching, [200]
  • -R โ€” Enable realignment mode
  • -A โ€” Keep contained reads during alignment
  • -s <float> โ€” Min similarity, calculated by kmer matched length / aligned length, [0.05]
  • -e <int> โ€” Min read depth of a valid edge, [3]
  • -q โ€” Quiet ๐Ÿคซ
  • -v โ€” Verbose (can be multiple). stack 'em like bracelets.
  • -V โ€” Print version information and then exit. bye bestie ๐Ÿ’…
  • --help โ€” Show more options. the door to the extended universe.

** more options ** โ€” the extended universe ๐ŸŒˆ

  • --cpu <int> โ€” See -t 0, default: all cores
  • --input <string> + โ€” See -i
  • --force โ€” See -f
  • --prefix <string> โ€” See -o
  • --preset <string> โ€” See -x
  • --kmer-fsize <int> โ€” See -k 0
  • --kmer-psize <int> โ€” See -p 21
  • --kmer-depth-max <float> โ€” See -K 1000.05
  • -E, --kmer-depth-min <int> โ€” Min kmer frequency, [2]
  • --kmer-subsampling <float> โ€” See -S 4.0
  • --kbm-parts <int> โ€” Split total reads into multiple parts, index one part by one to save memory, [1]
  • --aln-kmer-sampling <int> โ€” Select no more than n seeds in a query bin, default: 256
  • --dp-max-gap <int> โ€” Max number of bin(256bp) in one gap, [4]
  • --dp-max-var <int> โ€” Max number of bin(256bp) in one deviation, [4]
  • --dp-penalty-gap <int> โ€” Penalty for BIN gap, [-7]
  • --dp-penalty-var <int> โ€” Penalty for BIN deviation, [-21]
  • --aln-min-length <int> โ€” See -l 2048
  • --aln-min-match <int> โ€” See -m 200. Here the num of matches counting basepair of the matched kmer's regions
  • --aln-min-similarity <float> โ€” See -s 0.05
  • --aln-max-var <float> โ€” Max length variation of two aligned fragments, default: 0.25
  • --aln-dovetail <int> โ€” Retain dovetail overlaps only, the max overhang size is <--aln-dovetail>, the value should be times of 256, -1 to disable filtering, default: 256
  • --aln-strand <int> โ€” 1: forward, 2: reverse, 3: both. Please don't change the deault value 3, unless you exactly know what you are doing. > fr fr, do not touch this unless you know exactly what you're doing, bestie ๐Ÿšจ
  • --aln-maxhit <int> โ€” Max n hits for each read in build graph, default: 1000
  • --aln-bestn <int> โ€” Use best n hits for each read in build graph, 0: keep all, default: 500. <prefix>.alignments always store all alignments
  • -R, --realign โ€” Enable re-alignment, see --realn-kmer-psize=15, --realn-kmer-subsampling=1, --realn-min-length=2048, --realn-min-match=200, --realn-min-similarity=0.1, --realn-max-var=0.25
  • --realn-kmer-psize <int> โ€” Set kmer-psize in realignment, (kmer-ksize always eq 0), default: 15
  • --realn-kmer-subsampling <int> โ€” Set kmer-subsampling in realignment, default: 1
  • --realn-min-length <int> โ€” Set aln-min-length in realignment, default: 2048
  • --realn-min-match <int> โ€” Set aln-min-match in realignment, default: 200
  • --realn-min-similarity <float> โ€” Set aln-min-similarity in realignment, default: 0.1
  • --realn-max-var <float> โ€” Set aln-max-var in realignment, default: 0.25
  • -A, --aln-noskip โ€” Even a read was contained in previous alignment, still align it against other reads
  • --keep-multiple-alignment-parts โ€” By default, wtdbg will keep only the best alignment between two reads after chainning. This option will disable it, and keep multiple. she's keeping receipts, all of them ๐Ÿ’€
  • --verbose + โ€” See -v. -vvvv will display the most detailed information
  • --quiet โ€” See -q
  • --limit-input <int> โ€” Limit the input sequences to at most <int> M bp. Usually for test
  • -L <int>, --tidy-reads <int> โ€” Default: 0. Pick longest subreads if possible. Filter reads less than <--tidy-reads>. Please add --tidy-name or set --tidy-reads to nagetive value if want to rename reads. Set to 0 bp to disable tidy. Suggested value is 5000 for pacbio RSII reads
  • --tidy-name โ€” Rename reads into 'S%010d' format. The first read is named as S0000000001. glow-up + rebrand โœจ
  • --rdname-filter <string> โ€” A file contains lines of reads name to be discarded in loading. If you want to filter reads by yourself, please also set -X 0
  • --rdname-includeonly <string> โ€” Reverse manner with --rdname-filter
  • -g <number>, --genome-size <number> โ€” Provide genome size, e.g. 100.4m, 2.3g. In this version, it is used with -X/--rdcov-cutoff in selecting reads just after readed all.
  • -X <float>, --rdcov-cutoff <float> โ€” Default: 50.0. Retaining 50.0 folds of genome coverage, combined with -g and --rdcov-filter.
  • --rdcov-filter [0|1] โ€” Default 0. Strategy 0: retaining longest reads. Strategy 1: retaining medain length reads.
  • --err-free-nodes โ€” Select nodes from error-free-sequences only. E.g. you have contigs assembled from NGS-WGS reads, and long noisy reads. You can type '--err-free-seq your_ctg.fa --input your_long_reads.fa --err-free-nodes' to perform assembly somehow act as long-reads scaffolding. this combo is lowkey genius, iykyk ๐Ÿซถ
  • --node-len <int> โ€” The default value is 1024, which is times of KBM_BIN_SIZE(always equals 256 bp). It specifies the length of intervals (or call nodes after selecting). kbm indexs sequences into BINs of 256 bp in size, so that many parameter should be times of 256 bp. There are: --node-len, --node-ovl, --aln-min-length, --aln-dovetail . Other parameters are counted in BINs, --dp-max-gap, --dp-max-var .
  • --node-matched-bins <int> โ€” Min matched bins in a node, default: 1
  • --node-ovl <int> โ€” Default: 256. Max overlap size between two adjacent intervals in any read. It is used in selecting best nodes representing reads in graph
  • --node-drop <float> โ€” Default: 0.25. Will discard an node when has more this ratio intervals are conflicted with previous generated node
  • -e <int>, --edge-min=<int> โ€” Default: 3. The minimal depth of a valid edge is set to 3. In another word, Valid edges must be supported by at least 3 reads. When the sequence depth is low, have a try with --edge-min 2. Or very high, try --edge-min 4
  • --edge-max-span <int> โ€” Default: 1024 BINs. Program will build edges of length no large than 1024
  • --drop-low-cov-edges โ€” Don't attempt to rescue low coverage edges. not every edge gets saved, and that's okay ๐Ÿฅฒ
  • --node-min <int> โ€” Min depth of an interval to be selected as valid node. Defaultly, this value is automatically the same with --edge-min.
  • --node-max <int> โ€” Nodes with too high depth will be regarded as repetitive, and be masked. Default: 200, more than 200 reads contain this node
  • --ttr-cutoff-depth <int>, 0
  • --ttr-cutoff-ratio <float>, 0.5 โ€” Tiny Tandom Repeat. A node located inside ttr will bring noisy in graph, should be masked. The pattern of such nodes is: depth >= <--ttr-cutoff-depth>, and none of their edges have depth greater than depth * <--ttr-cutoff-ratio 0.5>. set --ttr-cutoff-depth 0 to disable ttr masking
  • --dump-kbm <string> โ€” Dump kbm index into file for loaded by kbm or wtdbg
  • --dump-seqs <string> โ€” Dump kbm index (only sequences, no k-mer index) into file for loaded by kbm or wtdbg. Please note: normally load it with --load-kbm, not with --load-seqs
  • --load-kbm <string> โ€” Instead of reading sequences and building kbm index, which is time-consumed, loading kbm-index from already dumped file. Please note that, once kbm-index is mmaped by kbm -R <kbm-index> start, will just get the shared memory in minute time. See kbm -R <your_seqs.kbmidx> [start | stop]. shared memory = instant serve, we love efficiency ๐Ÿ’…
  • --load-seqs <string> โ€” Similar with --load-kbm, but only use the sequences in kbmidx, and rebuild index in process's RAM.
  • --load-alignments <string> + โ€” wtdbg output reads' alignments into <--prefix>.alignments, program can load them to fastly build assembly graph. Or you can offer other source of alignments to wtdbg. When --load-alignment, will only reading long sequences but skip building kbm index. You can type --load-alignments <file> more than once to load alignments from many files
  • --load-clips <string> โ€” Combined with --load-nodes. Load reads clips. You can find it in wtdbg's <--prefix>.clps
  • --load-nodes <sting> โ€” Load dumped nodes from previous execution for fast construct the assembly graph, should be combined with --load-clips. You can find it in wtdbg's <--prefix>.1.nodes
  • --bubble-step <int>
  • --max-step <int> โ€” the max step you'll let it search a bubble, which is the max step from the starting node to the ending node. Default: 40 โœจ
  • --tip-step <int> โ€” same vibe but for tips: the max step it'll search a tip. Default: 10 ๐Ÿ’ซ
  • --ctg-min-length <int> โ€” min length a contig needs before it gets to be in the output. Default: 5000 ๐Ÿ“
  • --ctg-min-nodes <int> โ€” min number of nodes a contig needs before it gets to be in the output. Default: 3 ๐Ÿงฎ
  • --minimal-output โ€” ok bestie, this one's the "less is more" button. It'll generate as less output files (<--prefix>.*) as it can. Clutter? Not in this house. ๐ŸŽ€
  • --bin-complexity-cutoff <int> โ€” used when filtering BINs. If a BIN has less indexed valid kmers than <--bin-complexity-cutoff 2>, it masks it. ๐Ÿ”
  • --no-local-graph-analysis โ€” normally, before building edges, for each node, local-graph-analysis reads all the related reads and according nodes, and builds a local graph just to judge whether to mask it. The whole point of this analysis is finding repetitive nodes. Flip this flag and that whole detective arc doesn't happen. ๐Ÿ•ต๏ธโ€โ™€๏ธ
  • --no-read-length-sort โ€” defaultly, wtdbg sorts input sequences by length DSC. And the order of reads actually affects the generating of nodes in selecting important intervals, so yeah, this one matters. ๐Ÿ“Š
  • --keep-isolated-nodes โ€” in graph clean, wtdbg normally masks isolated (orphaned) nodes. This flag says leave the lonely ones alone. ๐Ÿฅบ
  • --no-read-clip โ€” defaultly, wtdbg clips an input sequence by analyzing its overlaps, which removes high error endings, rolling-circle repeats (see PacBio CCS), and chimera. When building edges, the clipped region won't contribute. However, wtdbg will still use them in the final linking of unitigs. So it's not gone-gone, it's just benched for part of the game. โœ‚๏ธ
  • --no-chainning-clip โ€” defaultly, it performs alignments chainning in read clipping. ** If you run '--aln-bestn 0 --no-read-clip', alignments will be parsed directly, and less RAM gets spent on recording alignments. Big brain memory move, ngl. ๐Ÿง 

๐Ÿ‘‘ AUTHOR

This manpage was written by Andreas Tille for the Debian distribution and can be used for any other usage of the program. ๐Ÿ’–


And that's the whole page, bestie โ€” wtdbg2 version 2.5, dated April 2020, manual section WTDBG2(1). Go assemble something iconic. ๐Ÿฆ‹โœจ