| 1 |
.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.47.8. |
| 2 |
.TH DEDUPE.SH "1" "April 2019" "dedupe.sh 38.43" "User Commands" |
| 3 |
.SH NAME |
| 4 |
dedupe.sh \- Simplifies assemblies by removing duplicate or contained |
| 5 |
.SH SYNOPSIS |
| 6 |
.B dedupe.sh |
| 7 |
\fI\,in=<file or stdin> out=<file or stdout>\/\fR |
| 8 |
.SH DESCRIPTION |
| 9 |
Accepts one or more files containing sets of sequences (reads or scaffolds). |
| 10 |
Removes duplicate sequences, which may be specified to be exact matches, subsequences, or sequences within some percent identity. |
| 11 |
Can also find overlapping sequences and group them into clusters. |
| 12 |
Please read bbmap/docs/guides/DedupeGuide.txt for more information. |
| 13 |
.SH EXAMPLES |
| 14 |
An example of running Dedupe for clustering short reads: |
| 15 |
.IP |
| 16 |
dedupe.sh in=x.fq am=f ac=f fo c pc rnc=f mcs=4 mo=100 s=1 pto cc qin=33 csf=stats.txt pattern=cluster_%.fq dot=graph.dot |
| 17 |
.PP |
| 18 |
Input may be fasta or fastq, compressed or uncompressed. |
| 19 |
Output may be stdout or a file. With no output parameter, data will be written to stdout. |
| 20 |
If 'out=null', there will be no output, but statistics will still be printed. |
| 21 |
You can also use 'dedupe <infile> <outfile>' without the 'in=' and 'out='. |
| 22 |
.SH OPTIONS |
| 23 |
.SS I/O parameters |
| 24 |
.TP |
| 25 |
in=<file,file> |
| 26 |
A single file or a comma\-delimited list of files. |
| 27 |
.TP |
| 28 |
out=<file> |
| 29 |
Destination for all output contigs. |
| 30 |
.TP |
| 31 |
pattern=<file> |
| 32 |
Clusters will be written to individual files, where the '%' symbol in the pattern is replaced by cluster number. |
| 33 |
.TP |
| 34 |
outd=<file> |
| 35 |
Optional; removed duplicates will go here. |
| 36 |
.TP |
| 37 |
csf=<file> |
| 38 |
(clusterstatsfile) Write a list of cluster names and sizes. |
| 39 |
.TP |
| 40 |
dot=<file> |
| 41 |
(graph) Write a graph in dot format. Requires 'fo' and 'pc' flags. |
| 42 |
.TP |
| 43 |
threads=auto |
| 44 |
(t) Set number of threads to use; default is number of logical processors. |
| 45 |
.TP |
| 46 |
overwrite=t |
| 47 |
(ow) Set to false to force the program to abort rather than overwrite an existing file. |
| 48 |
.TP |
| 49 |
showspeed=t |
| 50 |
(ss) Set to 'f' to suppress display of processing speed. |
| 51 |
.TP |
| 52 |
minscaf=0 |
| 53 |
(ms) Ignore contigs/scaffolds shorter than this. |
| 54 |
.TP |
| 55 |
interleaved=auto |
| 56 |
If true, forces fastq input to be paired and interleaved. |
| 57 |
.TP |
| 58 |
ziplevel=2 |
| 59 |
Set to 1 (lowest) through 9 (max) to change compression level; lower compression is faster. |
| 60 |
.SS Output format parameters |
| 61 |
.TP |
| 62 |
storename=t |
| 63 |
(sn) Store scaffold names (set false to save memory). |
| 64 |
.TP |
| 65 |
#addpairnum=f |
| 66 |
Add .1 and .2 to numeric id of read1 and read2. |
| 67 |
.TP |
| 68 |
storequality=t |
| 69 |
(sq) Store quality values for fastq assemblies (set false to save memory). |
| 70 |
.TP |
| 71 |
uniquenames=t |
| 72 |
(un) Ensure all output scaffolds have unique names. Uses more memory. |
| 73 |
.TP |
| 74 |
numbergraphnodes=t |
| 75 |
(ngn) Label dot graph nodes with read numbers rather than read names. |
| 76 |
.TP |
| 77 |
sort=f |
| 78 |
Sort output (otherwise it will be random). Options: |
| 79 |
.IP |
| 80 |
length: Sort by length |
| 81 |
.IP |
| 82 |
quality: Sort by quality |
| 83 |
.IP |
| 84 |
name: Sort by name |
| 85 |
.IP |
| 86 |
id: Sort by input order |
| 87 |
.TP |
| 88 |
ascending=f |
| 89 |
Sort in ascending order. |
| 90 |
.TP |
| 91 |
ordered=f |
| 92 |
Output sequences in input order. Equivalent to sort=id ascending. |
| 93 |
.TP |
| 94 |
renameclusters=f |
| 95 |
(rnc) Rename contigs to indicate which cluster they are in. |
| 96 |
.TP |
| 97 |
printlengthinedges=f |
| 98 |
(ple) Print the length of contigs in edges. |
| 99 |
.SS Processing parameters |
| 100 |
.TP |
| 101 |
absorbrc=t |
| 102 |
(arc) Absorb reverse\-complements as well as normal orientation. |
| 103 |
.TP |
| 104 |
absorbmatch=t |
| 105 |
(am) Absorb exact matches of contigs. |
| 106 |
.TP |
| 107 |
absorbcontainment=t |
| 108 |
(ac) Absorb full containments of contigs. |
| 109 |
.TP |
| 110 |
#absorboverlap=f |
| 111 |
(ao) Absorb (merge) non\-contained overlaps of contigs (TODO). |
| 112 |
.TP |
| 113 |
findoverlap=f |
| 114 |
(fo) Find overlaps between contigs (containments and non\-containments). Necessary for clustering. |
| 115 |
.TP |
| 116 |
uniqueonly=f |
| 117 |
(uo) If true, all copies of duplicate reads will be discarded, rather than keeping 1. |
| 118 |
.TP |
| 119 |
rmn=f |
| 120 |
(requirematchingnames) If true, both names and sequence must match. |
| 121 |
.TP |
| 122 |
usejni=f |
| 123 |
(jni) Do alignments in C code, which is faster, if an edit distance is allowed. |
| 124 |
This will require compiling the C code; details are in \fI\,/jni/README.txt\/\fP. |
| 125 |
.SS Subset parameters |
| 126 |
.TP |
| 127 |
subsetcount=1 |
| 128 |
(sstc) Number of subsets used to process the data; higher uses less memory. |
| 129 |
.TP |
| 130 |
subset=0 |
| 131 |
(sst) Only process reads whose ((ID%subsetcount)==subset). |
| 132 |
.SS Clustering parameters |
| 133 |
.TP |
| 134 |
cluster=f |
| 135 |
(c) Group overlapping contigs into clusters. |
| 136 |
.TP |
| 137 |
pto=f |
| 138 |
(preventtransitiveoverlaps) Do not look for new edges between nodes in the same cluster. |
| 139 |
.TP |
| 140 |
minclustersize=1 |
| 141 |
(mcs) Do not output clusters smaller than this. |
| 142 |
.TP |
| 143 |
pbr=f |
| 144 |
(pickbestrepresentative) Only output the single highest\-quality read per cluster. |
| 145 |
.SS Cluster postprocessing parameters |
| 146 |
.TP |
| 147 |
processclusters=f |
| 148 |
(pc) Run the cluster processing phase, which performs the selected operations in this category. |
| 149 |
For example, pc AND cc must be enabled to perform cc. |
| 150 |
.TP |
| 151 |
fixmultijoins=t |
| 152 |
(fmj) Remove redundant overlaps between the same two contigs. |
| 153 |
.TP |
| 154 |
removecycles=t |
| 155 |
(rc) Remove all cycles so clusters form trees. |
| 156 |
.TP |
| 157 |
cc=t |
| 158 |
(canonicizeclusters) Flip contigs so clusters have a single orientation. |
| 159 |
.TP |
| 160 |
fcc=f |
| 161 |
(fixcanoncontradictions) Truncate graph at nodes with canonization disputes. |
| 162 |
.TP |
| 163 |
foc=f |
| 164 |
(fixoffsetcontradictions) Truncate graph at nodes with offset disputes. |
| 165 |
.TP |
| 166 |
mst=f |
| 167 |
(maxspanningtree) Remove cyclic edges, leaving only the longest edges that form a tree. |
| 168 |
.SS Overlap Detection Parameters |
| 169 |
.TP |
| 170 |
exact=t |
| 171 |
(ex) Only allow exact symbol matches. When false, an 'N' will match any symbol. |
| 172 |
.TP |
| 173 |
touppercase=t |
| 174 |
(tuc) Convert input bases to upper\-case; otherwise, lower\-case will not match. |
| 175 |
.TP |
| 176 |
maxsubs=0 |
| 177 |
(s) Allow up to this many mismatches (substitutions only, no indels). May be set higher than maxedits. |
| 178 |
.TP |
| 179 |
maxedits=0 |
| 180 |
(e) Allow up to this many edits (subs or indels). Higher is slower. |
| 181 |
.TP |
| 182 |
minidentity=100 |
| 183 |
(mid) Absorb contained sequences with percent identity of at least this (includes indels). |
| 184 |
.TP |
| 185 |
minlengthpercent=0 |
| 186 |
(mlp) Smaller contig must be at least this percent of larger contig's length to be absorbed. |
| 187 |
.TP |
| 188 |
minoverlappercent=0 |
| 189 |
(mop) Overlap must be at least this percent of smaller contig's length to cluster and merge. |
| 190 |
.TP |
| 191 |
minoverlap=200 |
| 192 |
(mo) Overlap must be at least this long to cluster and merge. |
| 193 |
.TP |
| 194 |
depthratio=0 |
| 195 |
(dr) When non\-zero, overlaps will only be formed between reads with a depth ratio of at most this. |
| 196 |
Should be above 1. |
| 197 |
Depth is determined by parsing the read names; this information can be added |
| 198 |
by running KmerNormalize (khist.sh, bbnorm.sh, or ecc.sh) with the flag 'rename' |
| 199 |
.TP |
| 200 |
k=31 |
| 201 |
Seed length used for finding containments and overlaps. Anything shorter than k will not be found. |
| 202 |
.TP |
| 203 |
numaffixmaps=1 |
| 204 |
(nam) Number of prefixes/suffixes to index per contig. Higher is more sensitive, if edits are allowed. |
| 205 |
.TP |
| 206 |
hashns=f |
| 207 |
Set to true to search for matches using kmers containing Ns. Can lead to extreme slowdown in some cases. |
| 208 |
.TP |
| 209 |
#ignoreaffix1=f |
| 210 |
(ia1) Ignore first affix (for testing). |
| 211 |
.TP |
| 212 |
#storesuffix=f |
| 213 |
(ss) Store suffix as well as prefix. Automatically set to true when doing inexact matches. |
| 214 |
.SS Other Parameters |
| 215 |
.TP |
| 216 |
qtrim=f |
| 217 |
Set to qtrim=rl to trim leading and trailing Ns. |
| 218 |
.TP |
| 219 |
trimq=6 |
| 220 |
Quality trim level. |
| 221 |
.TP |
| 222 |
forcetrimleft=\-1 |
| 223 |
(ftl) If positive, trim bases to the left of this position (exclusive, 0\-based). |
| 224 |
.TP |
| 225 |
forcetrimright=\-1 |
| 226 |
(ftr) If positive, trim bases to the right of this position (exclusive, 0\-based). |
| 227 |
.SS Note on Proteins / Amino Acids |
| 228 |
Dedupe supports amino acid space via the 'amino' flag. This also changes the default kmer length to 10. |
| 229 |
In amino acid mode, all flags related to canonicity and reverse\-complementation are disabled, |
| 230 |
and nam (numaffixmaps) is currently limited to 2 per tip. |
| 231 |
.SS Java Parameters |
| 232 |
.TP |
| 233 |
\fB\-Xmx\fR |
| 234 |
This will set Java's memory usage, overriding autodetection. |
| 235 |
.IP |
| 236 |
\fB\-Xmx20g\fR will specify 20 gigs of RAM, and \fB\-Xmx200m\fR will specify 200 megs. |
| 237 |
The max is typically 85% of physical memory. |
| 238 |
.TP |
| 239 |
\fB\-eoom\fR |
| 240 |
This flag will cause the process to exit if an out\-of\-memory exception occurs. Requires Java 8u92+. |
| 241 |
.TP |
| 242 |
\fB\-da\fR |
| 243 |
Disable assertions. |
| 244 |
.SH AUTHOR |
| 245 |
Written by Brian Bushnell and Jonathan Rood (Last modified November 20, 2017) |
| 246 |
.P |
| 247 |
Please contact Brian Bushnell at [email protected] if you encounter any problems. |
| 248 |
.P |
| 249 |
This manpage was written by Andreas Tille for the Debian distribution and can be used for any other usage of the program. |