annotate 0.5.0/lib/help/fastp.nf @ 0:97cd2f532efe

planemo upload
author kkonganti
date Mon, 31 Mar 2025 14:50:40 -0400
parents
children
rev   line source
kkonganti@0 1 // Help text for fastp within CPIPES.
kkonganti@0 2
kkonganti@0 3 def fastpHelp(params) {
kkonganti@0 4
kkonganti@0 5 Map tool = [:]
kkonganti@0 6 Map toolspecs = [:]
kkonganti@0 7 tool.text = [:]
kkonganti@0 8 tool.helpparams = [:]
kkonganti@0 9
kkonganti@0 10 toolspecs = [
kkonganti@0 11 'fastp_run': [
kkonganti@0 12 clihelp: 'Run fastp tool. Default: ' +
kkonganti@0 13 (params.fastp_run ?: false),
kkonganti@0 14 cliflag: null,
kkonganti@0 15 clivalue: null
kkonganti@0 16 ],
kkonganti@0 17 'fastp_failed_out': [
kkonganti@0 18 clihelp: 'Specify whether to store reads that cannot pass the filters. ' +
kkonganti@0 19 "Default: ${params.fastp_failed_out}",
kkonganti@0 20 cliflag: null,
kkonganti@0 21 clivalue: null
kkonganti@0 22 ],
kkonganti@0 23 'fastp_merged_out': [
kkonganti@0 24 clihelp: 'Specify whether to store merged output or not. ' +
kkonganti@0 25 "Default: ${params.fastp_merged_out}",
kkonganti@0 26 cliflag: null,
kkonganti@0 27 clivalue: null
kkonganti@0 28 ],
kkonganti@0 29 'fastp_overlapped_out': [
kkonganti@0 30 clihelp: 'For each read pair, output the overlapped region if it has no mismatched base. ' +
kkonganti@0 31 "Default: ${params.fastp_overlapped_out}",
kkonganti@0 32 cliflag: '--overlapped_out',
kkonganti@0 33 clivalue: (params.fastp_overlapped_out ?: '')
kkonganti@0 34 ],
kkonganti@0 35 'fastp_6': [
kkonganti@0 36 clihelp: "Indicate that the input is using phred64 scoring (it'll be converted to phred33, " +
kkonganti@0 37 'so the output will still be phred33). ' +
kkonganti@0 38 "Default: ${params.fastp_6}",
kkonganti@0 39 cliflag: '-6',
kkonganti@0 40 clivalue: (params.fastp_6 ? ' ' : '')
kkonganti@0 41 ],
kkonganti@0 42 'fastp_reads_to_process': [
kkonganti@0 43 clihelp: 'Specify how many reads/pairs are to be processed. Default value 0 means ' +
kkonganti@0 44 'process all reads. ' +
kkonganti@0 45 "Default: ${params.fastp_reads_to_process}",
kkonganti@0 46 cliflag: '--reads_to_process',
kkonganti@0 47 clivalue: (params.fastp_reads_to_process ?: '')
kkonganti@0 48 ],
kkonganti@0 49 'fastp_fix_mgi_id': [
kkonganti@0 50 clihelp: 'The MGI FASTQ ID format is not compatible with many BAM operation tools, ' +
kkonganti@0 51 'enable this option to fix it. ' +
kkonganti@0 52 "Default: ${params.fastp_fix_mgi_id}",
kkonganti@0 53 cliflag: '--fix_mgi_id',
kkonganti@0 54 clivalue: (params.fastp_fix_mgi_id ? ' ' : '')
kkonganti@0 55 ],
kkonganti@0 56 'fastp_A': [
kkonganti@0 57 clihelp: 'Disable adapter trimming. On by default. ' +
kkonganti@0 58 "Default: ${params.fastp_A}",
kkonganti@0 59 cliflag: '-A',
kkonganti@0 60 clivalue: (params.fastp_A ? ' ' : '')
kkonganti@0 61 ],
kkonganti@0 62 'fastp_adapter_fasta': [
kkonganti@0 63 clihelp: 'Specify a FASTA file to trim both read1 and read2 (if PE) by all the sequences ' +
kkonganti@0 64 'in this FASTA file. ' +
kkonganti@0 65 "Default: ${params.fastp_adapter_fasta}",
kkonganti@0 66 cliflag: '--adapter_fasta',
kkonganti@0 67 clivalue: (params.fastp_adapter_fasta ?: '')
kkonganti@0 68 ],
kkonganti@0 69 'fastp_f': [
kkonganti@0 70 clihelp: 'Trim how many bases in front of read1. ' +
kkonganti@0 71 "Default: ${params.fastp_f}",
kkonganti@0 72 cliflag: '-f',
kkonganti@0 73 clivalue: (params.fastp_f ?: '')
kkonganti@0 74 ],
kkonganti@0 75 'fastp_t': [
kkonganti@0 76 clihelp: 'Trim how many bases at the end of read1. ' +
kkonganti@0 77 "Default: ${params.fastp_t}",
kkonganti@0 78 cliflag: '-t',
kkonganti@0 79 clivalue: (params.fastp_t ?: '')
kkonganti@0 80 ],
kkonganti@0 81 'fastp_b': [
kkonganti@0 82 clihelp: 'Max length of read1 after trimming. ' +
kkonganti@0 83 "Default: ${params.fastp_b}",
kkonganti@0 84 cliflag: '-b',
kkonganti@0 85 clivalue: (params.fastp_b ?: '')
kkonganti@0 86 ],
kkonganti@0 87 'fastp_F': [
kkonganti@0 88 clihelp: 'Trim how many bases in front of read2. ' +
kkonganti@0 89 "Default: ${params.fastp_F}",
kkonganti@0 90 cliflag: '-F',
kkonganti@0 91 clivalue: (params.fastp_F ?: '')
kkonganti@0 92 ],
kkonganti@0 93 'fastp_T': [
kkonganti@0 94 clihelp: 'Trim how many bases at the end of read2. ' +
kkonganti@0 95 "Default: ${params.fastp_T}",
kkonganti@0 96 cliflag: '-T',
kkonganti@0 97 clivalue: (params.fastp_T ?: '')
kkonganti@0 98 ],
kkonganti@0 99 'fastp_B': [
kkonganti@0 100 clihelp: 'Max length of read2 after trimming. ' +
kkonganti@0 101 "Default: ${params.fastp_B}",
kkonganti@0 102 cliflag: '-B',
kkonganti@0 103 clivalue: (params.fastp_B ?: '')
kkonganti@0 104 ],
kkonganti@0 105 'fastp_dedup': [
kkonganti@0 106 clihelp: 'Enable deduplication to drop the duplicated reads/pairs. ' +
kkonganti@0 107 "Default: ${params.fastp_dedup}",
kkonganti@0 108 cliflag: '--dedup',
kkonganti@0 109 clivalue: (params.fastp_dedup ? ' ' : '')
kkonganti@0 110 ],
kkonganti@0 111 'fastp_dup_calc_accuracy': [
kkonganti@0 112 clihelp: 'Accuracy level to calculate duplication (1~6), higher level uses more memory ' +
kkonganti@0 113 '(1G, 2G, 4G, 8G, 16G, 24G). Default 1 for no-dedup mode, and 3 for dedup mode. ' +
kkonganti@0 114 "Default: ${params.fastp_dup_calc_accuracy}",
kkonganti@0 115 cliflag: '--dup_calc_accuracy',
kkonganti@0 116 clivalue: (params.fastp_dup_calc_accuracy ?: '')
kkonganti@0 117 ],
kkonganti@0 118 'fastp_poly_g_min_len': [
kkonganti@0 119 clihelp: 'The minimum length to detect polyG in the read tail. ' +
kkonganti@0 120 "Default: ${params.fastp_poly_g_min_len}",
kkonganti@0 121 cliflag: '--poly_g_min_len',
kkonganti@0 122 clivalue: (params.fastp_poly_g_min_len ?: '')
kkonganti@0 123 ],
kkonganti@0 124 'fastp_G': [
kkonganti@0 125 clihelp: 'Disable polyG tail trimming. ' +
kkonganti@0 126 "Default: ${params.fastp_G}",
kkonganti@0 127 cliflag: '-G',
kkonganti@0 128 clivalue: (params.fastp_G ? ' ' : '')
kkonganti@0 129 ],
kkonganti@0 130 'fastp_x': [
kkonganti@0 131 clihelp: "Enable polyX trimming in 3' ends. " +
kkonganti@0 132 "Default: ${params.fastp_x}",
kkonganti@0 133 cliflag: 'x=',
kkonganti@0 134 clivalue: (params.fastp_x ? ' ' : '')
kkonganti@0 135 ],
kkonganti@0 136 'fastp_poly_x_min_len': [
kkonganti@0 137 clihelp: 'The minimum length to detect polyX in the read tail. ' +
kkonganti@0 138 "Default: ${params.fastp_poly_x_min_len}",
kkonganti@0 139 cliflag: '--poly_x_min_len',
kkonganti@0 140 clivalue: (params.fastp_poly_x_min_len ?: '')
kkonganti@0 141 ],
kkonganti@0 142 'fastp_cut_front': [
kkonganti@0 143 clihelp: "Move a sliding window from front (5') to tail, drop the bases in the window " +
kkonganti@0 144 'if its mean quality < threshold, stop otherwise. ' +
kkonganti@0 145 "Default: ${params.fastp_cut_front}",
kkonganti@0 146 cliflag: '--cut_front',
kkonganti@0 147 clivalue: (params.fastp_cut_front ? ' ' : '')
kkonganti@0 148 ],
kkonganti@0 149 'fastp_cut_tail': [
kkonganti@0 150 clihelp: "Move a sliding window from tail (3') to front, drop the bases in the window " +
kkonganti@0 151 'if its mean quality < threshold, stop otherwise. ' +
kkonganti@0 152 "Default: ${params.fastp_cut_tail}",
kkonganti@0 153 cliflag: '--cut_tail',
kkonganti@0 154 clivalue: (params.fastp_cut_tail ? ' ' : '')
kkonganti@0 155 ],
kkonganti@0 156 'fastp_cut_right': [
kkonganti@0 157 clihelp: "Move a sliding window from tail, drop the bases in the window and the right part " +
kkonganti@0 158 'if its mean quality < threshold, and then stop. ' +
kkonganti@0 159 "Default: ${params.fastp_cut_right}",
kkonganti@0 160 cliflag: '--cut_right',
kkonganti@0 161 clivalue: (params.fastp_cut_right ? ' ' : '')
kkonganti@0 162 ],
kkonganti@0 163 'fastp_W': [
kkonganti@0 164 clihelp: "Sliding window size shared by --fastp_cut_front, --fastp_cut_tail and " +
kkonganti@0 165 '--fastp_cut_right. ' +
kkonganti@0 166 "Default: ${params.fastp_W}",
kkonganti@0 167 cliflag: '--cut_window_size',
kkonganti@0 168 clivalue: (params.fastp_W ?: '')
kkonganti@0 169 ],
kkonganti@0 170 'fastp_M': [
kkonganti@0 171 clihelp: "The mean quality requirement shared by --fastp_cut_front, --fastp_cut_tail and " +
kkonganti@0 172 '--fastp_cut_right. ' +
kkonganti@0 173 "Default: ${params.fastp_M}",
kkonganti@0 174 cliflag: '--cut_mean_quality',
kkonganti@0 175 clivalue: (params.fastp_M ?: '')
kkonganti@0 176 ],
kkonganti@0 177 'fastp_q': [
kkonganti@0 178 clihelp: 'The quality value below which a base should is not qualified. ' +
kkonganti@0 179 "Default: ${params.fastp_q}",
kkonganti@0 180 cliflag: '-q',
kkonganti@0 181 clivalue: (params.fastp_q ?: '')
kkonganti@0 182 ],
kkonganti@0 183 'fastp_u': [
kkonganti@0 184 clihelp: 'What percent of bases are allowed to be unqualified. ' +
kkonganti@0 185 "Default: ${params.fastp_u}",
kkonganti@0 186 cliflag: '-u',
kkonganti@0 187 clivalue: (params.fastp_u ?: '')
kkonganti@0 188 ],
kkonganti@0 189 'fastp_n': [
kkonganti@0 190 clihelp: "How many N's can a read have. " +
kkonganti@0 191 "Default: ${params.fastp_n}",
kkonganti@0 192 cliflag: '-n',
kkonganti@0 193 clivalue: (params.fastp_n ?: '')
kkonganti@0 194 ],
kkonganti@0 195 'fastp_e': [
kkonganti@0 196 clihelp: "If the full reads' average quality is below this value, then it is discarded. " +
kkonganti@0 197 "Default: ${params.fastp_e}",
kkonganti@0 198 cliflag: '-e',
kkonganti@0 199 clivalue: (params.fastp_e ?: '')
kkonganti@0 200 ],
kkonganti@0 201 'fastp_l': [
kkonganti@0 202 clihelp: 'Reads shorter than this length will be discarded. ' +
kkonganti@0 203 "Default: ${params.fastp_l}",
kkonganti@0 204 cliflag: '-l',
kkonganti@0 205 clivalue: (params.fastp_l ?: '')
kkonganti@0 206 ],
kkonganti@0 207 'fastp_max_len': [
kkonganti@0 208 clihelp: 'Reads longer than this length will be discarded. ' +
kkonganti@0 209 "Default: ${params.fastp_max_len}",
kkonganti@0 210 cliflag: '--length_limit',
kkonganti@0 211 clivalue: (params.fastp_max_len ?: '')
kkonganti@0 212 ],
kkonganti@0 213 'fastp_y': [
kkonganti@0 214 clihelp: 'Enable low complexity filter. The complexity is defined as the percentage ' +
kkonganti@0 215 'of bases that are different from its next base (base[i] != base[i+1]). ' +
kkonganti@0 216 "Default: ${params.fastp_y}",
kkonganti@0 217 cliflag: '-y',
kkonganti@0 218 clivalue: (params.fastp_y ? ' ' : '')
kkonganti@0 219 ],
kkonganti@0 220 'fastp_Y': [
kkonganti@0 221 clihelp: 'The threshold for low complexity filter (0~100). Ex: A value of 30 means ' +
kkonganti@0 222 '30% complexity is required. ' +
kkonganti@0 223 "Default: ${params.fastp_Y}",
kkonganti@0 224 cliflag: '-Y',
kkonganti@0 225 clivalue: (params.fastp_Y ?: '')
kkonganti@0 226 ],
kkonganti@0 227 'fastp_U': [
kkonganti@0 228 clihelp: 'Enable Unique Molecular Identifier (UMI) pre-processing. ' +
kkonganti@0 229 "Default: ${params.fastp_U}",
kkonganti@0 230 cliflag: '-U',
kkonganti@0 231 clivalue: (params.fastp_U ? ' ' : '')
kkonganti@0 232 ],
kkonganti@0 233 'fastp_umi_loc': [
kkonganti@0 234 clihelp: 'Specify the location of UMI, can be one of ' +
kkonganti@0 235 'index1/index2/read1/read2/per_index/per_read. ' +
kkonganti@0 236 "Default: ${params.fastp_umi_loc}",
kkonganti@0 237 cliflag: '--umi_loc',
kkonganti@0 238 clivalue: (params.fastp_umi_loc ?: '')
kkonganti@0 239 ],
kkonganti@0 240 'fastp_umi_len': [
kkonganti@0 241 clihelp: 'If the UMI is in read1 or read2, its length should be provided. ' +
kkonganti@0 242 "Default: ${params.fastp_umi_len}",
kkonganti@0 243 cliflag: '--umi_len',
kkonganti@0 244 clivalue: (params.fastp_umi_len ?: '')
kkonganti@0 245 ],
kkonganti@0 246 'fastp_umi_prefix': [
kkonganti@0 247 clihelp: 'If specified, an underline will be used to connect prefix and UMI ' +
kkonganti@0 248 '(i.e. prefix=UMI, UMI=AATTCG, final=UMI_AATTCG). ' +
kkonganti@0 249 "Default: ${params.fastp_umi_prefix}",
kkonganti@0 250 cliflag: '--umi_prefix',
kkonganti@0 251 clivalue: (params.fastp_umi_prefix ?: '')
kkonganti@0 252 ],
kkonganti@0 253 'fastp_umi_skip': [
kkonganti@0 254 clihelp: 'If the UMI is in read1 or read2, fastp can skip several bases following the UMI. ' +
kkonganti@0 255 "Default: ${params.fastp_umi_skip}",
kkonganti@0 256 cliflag: '--umi_skip',
kkonganti@0 257 clivalue: (params.fastp_umi_skip ?: '')
kkonganti@0 258 ],
kkonganti@0 259 'fastp_p': [
kkonganti@0 260 clihelp: 'Enable overrepresented sequence analysis. ' +
kkonganti@0 261 "Default: ${params.fastp_p}",
kkonganti@0 262 cliflag: '-p',
kkonganti@0 263 clivalue: (params.fastp_p ? ' ' : '')
kkonganti@0 264 ],
kkonganti@0 265 'fastp_P': [
kkonganti@0 266 clihelp: 'One in this many number of reads will be computed for overrepresentation analysis ' +
kkonganti@0 267 '(1~10000), smaller is slower. ' +
kkonganti@0 268 "Default: ${params.fastp_P}",
kkonganti@0 269 cliflag: '-P',
kkonganti@0 270 clivalue: (params.fastp_P ?: '')
kkonganti@0 271 ]
kkonganti@0 272 ]
kkonganti@0 273
kkonganti@0 274 toolspecs.each {
kkonganti@0 275 k, v -> tool.text['--' + k] = "${v.clihelp}"
kkonganti@0 276 tool.helpparams[k] = [ cliflag: "${v.cliflag}", clivalue: v.clivalue ]
kkonganti@0 277 }
kkonganti@0 278
kkonganti@0 279 return tool
kkonganti@0 280 }