comparison trim_galore.xml @ 16:cd7e644cae1d draft default tip

"planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/trim_galore commit 276a0ec327f5369c16563696047f0d31577c353f"
author bgruening
date Fri, 08 Oct 2021 09:57:52 +0000
parents 084bbd8ba7b8
children
comparison
equal deleted inserted replaced
15:084bbd8ba7b8 16:cd7e644cae1d
1 <tool id="trim_galore" name="Trim Galore!" version="0.6.3" profile="17.01"> 1 <tool id="trim_galore" name="Trim Galore!" version="@TOOL_VERSION@+galaxy@VERSION_SUFFIX@" profile="20.01">
2 <!-- Wrapper compatible with Trim Galore! version 0.6.3 -->
3 <description>Quality and adapter trimmer of reads</description> 2 <description>Quality and adapter trimmer of reads</description>
4 <macros> 3 <macros>
5 <macro name="adapter_trimming"> 4 <import>macros.xml</import>
6 <conditional name="trimming">
7 <param name="trimming_select" type="select" label="Adapter sequence to be trimmed">
8 <option value="">Automatic detection</option>
9 <option value="--illumina">Illumina universal</option>
10 <option value="--nextera">Nextera transposase</option>
11 <option value="--small_rna">Illumina small RNA adapters</option>
12 <option value="user">User defined adapter sequence</option>
13 </param>
14 <when value=""/>
15 <when value="--illumina"/>
16 <when value="--nextera"/>
17 <when value="--small_rna"/>
18 <when value="user">
19 <param name="adapter" type="text" value="AGATCGGAAGAGC" label="Adapter sequence to be trimmed off">
20 <validator type="regex" message="Adapter sequence must contain DNA characters only (A,C,T,G or N)">^[ACTGNactgn]*$</validator>
21 </param>
22 <yield/>
23 </when>
24 </conditional>
25 </macro>
26 <macro name="paired_adapter_trimming">
27 <expand macro="adapter_trimming">
28 <param name="adapter2" type="text" optional="True" value="" label="Adapter sequence to be trimmed off read 2">
29 <validator type="regex" message="Adapter sequence must contain DNA characters only (A,C,T,G or N)">^[ACTGNactgn]*$</validator>
30 </param>
31 </expand>
32 <param name="trim1" type="boolean" truevalue="--trim1" falsevalue="" checked="False" label="Trims 1 bp off every read from its 3' end." help="" />
33 <param name="three_prime_clip_R1" type="integer" value="" optional="True" label="Remove N bp from the 3' end of read 1">
34 <help>Instructs Trim Galore! to remove N bp from the 3' end of read 1 after adapter/quality trimming has been performed.
35 This may remove some unwanted bias from the 3' end that is not directly related to adapter sequence or basecall quality.
36 (--three_prime_clip_R1)</help>
37 </param>
38 <param name="three_prime_clip_R2" type="integer" value="" optional="True" label="Remove N bp from the 3' end of read 2">
39 <help>Instructs Trim Galore! to remove N bp from the 3' end of read 2 after
40 adapter/quality trimming has been performed. This may remove some unwanted bias from
41 the 3' end that is not directly related to adapter sequence or basecall quality.</help>
42 </param>
43 </macro>
44 </macros> 5 </macros>
45 <requirements> 6 <expand macro="requirements" />
46 <requirement type="package" version="0.6.3">trim-galore</requirement> 7 <expand macro="xrefs"/>
47 </requirements>
48 <version_command> 8 <version_command>
49 trim_galore --version 9 trim_galore --version
50 </version_command> 10 </version_command>
51 <command detect_errors="aggressive"><![CDATA[ 11 <command detect_errors="aggressive"><![CDATA[
52 #set compressed = 'no' 12 #set compressed = 'no'
90 ln -s '${singlePaired.input_mate_pairs.reverse}' ${read2} && 50 ln -s '${singlePaired.input_mate_pairs.reverse}' ${read2} &&
91 #end if 51 #end if
92 52
93 trim_galore 53 trim_galore
94 54
55 ## according the develpers 4 cores could be a sweet spot, anything above has diminishing returns
56 --cores \${GALAXY_SLOTS:-4}
57
95 ## we only support fastqsanger 58 ## we only support fastqsanger
96 --phred33 59 --phred33
97 60
98 #if $params.settingsType == "custom": 61 #if $params.settingsType == "custom":
99 62
173 ${read2} 136 ${read2}
174 #end if 137 #end if
175 138
176 #if $compressed == 'no': 139 #if $compressed == 'no':
177 --dont_gzip 140 --dont_gzip
141 #end if
142
143 ## Trimming settings
144 #if $trimming.settingsType == 'custom'
145 #if $trimming.hardtrim5
146 --hardtrim5 $trimming.hardtrim5
147 #end if
148 #if $trimming.hardtrim3
149 --hardtrim3 $trimming.hardtrim3
150 #end if
151 $trimming.clock
152 $trimming.polyA
178 #end if 153 #end if
179 154
180 ## Trim Galore is finished, rename the output if compressed 155 ## Trim Galore is finished, rename the output if compressed
181 && 156 &&
182 if [ -f input_1_trimmed.fq.gz ] ; then mv input_1_trimmed.fq.gz input_1_trimmed.fq ; fi 157 if [ -f input_1_trimmed.fq.gz ] ; then mv input_1_trimmed.fq.gz input_1_trimmed.fq ; fi
186 if [ -f input_2_val_2.fq.gz ] ; then mv input_2_val_2.fq.gz input_2_val_2.fq ; fi 161 if [ -f input_2_val_2.fq.gz ] ; then mv input_2_val_2.fq.gz input_2_val_2.fq ; fi
187 && 162 &&
188 if [ -f input_1_unpaired_1.fq.gz ] ; then mv input_1_unpaired_1.fq.gz input_1_unpaired_1.fq ; fi 163 if [ -f input_1_unpaired_1.fq.gz ] ; then mv input_1_unpaired_1.fq.gz input_1_unpaired_1.fq ; fi
189 && 164 &&
190 if [ -f input_2_unpaired_2.fq.gz ] ; then mv input_2_unpaired_2.fq.gz input_2_unpaired_2.fq ; fi 165 if [ -f input_2_unpaired_2.fq.gz ] ; then mv input_2_unpaired_2.fq.gz input_2_unpaired_2.fq ; fi
166 &&
167 if [ -f input_1.clock_UMI.R1.fq.gz ] ; then mv input_1.clock_UMI.R1.fq.gz input_1.clock_UMI.R1.fq ; fi
168 &&
169 if [ -f input_2.clock_UMI.R2.fq.gz ] ; then mv input_2.clock_UMI.R2.fq.gz input_2.clock_UMI.R2.fq ; fi
170
171 ## Rename hardtrimmed files
172 #if $trimming.settingsType == 'custom'
173 &&
174 if [ -f input_1.${trimming.hardtrim5}bp_5prime.fq.gz ] ; then mv input_1.${trimming.hardtrim5}bp_5prime.fq.gz input_1_hardtrim.fq ; fi
175 &&
176 if [ -f input_2.${trimming.hardtrim5}bp_5prime.fq.gz ] ; then mv input_2.${trimming.hardtrim5}bp_5prime.fq.gz input_2_hardtrim.fq ; fi
177 &&
178 if [ -f input_1.${trimming.hardtrim3}bp_3prime.fq.gz ] ; then mv input_1.${trimming.hardtrim3}bp_3prime.fq.gz input_1_hardtrim.fq ; fi
179 &&
180 if [ -f input_2.${trimming.hardtrim3}bp_3prime.fq.gz ] ; then mv input_2.${trimming.hardtrim3}bp_3prime.fq.gz input_2_hardtrim.fq ; fi
181 &&
182 if [ -f input_1.${trimming.hardtrim5}bp_5prime.fq ] ; then mv input_1.${trimming.hardtrim5}bp_5prime.fq input_1_hardtrim.fq ; fi
183 &&
184 if [ -f input_2.${trimming.hardtrim5}bp_5prime.fq ] ; then mv input_2.${trimming.hardtrim5}bp_5prime.fq input_2_hardtrim.fq ; fi
185 &&
186 if [ -f input_1.${trimming.hardtrim3}bp_3prime.fq ] ; then mv input_1.${trimming.hardtrim3}bp_3prime.fq input_1_hardtrim.fq ; fi
187 &&
188 if [ -f input_2.${trimming.hardtrim3}bp_3prime.fq ] ; then mv input_2.${trimming.hardtrim3}bp_3prime.fq input_2_hardtrim.fq ; fi
189 #end if
191 190
192 ## Trim Galore! run is finished. Move the report files to the proper place 191 ## Trim Galore! run is finished. Move the report files to the proper place
193 #if $params.settingsType == "custom" and $params.report: 192 #if $params.settingsType == "custom" and $params.report:
194 && 193 &&
195 cat ./*_trimming_report.txt > '$report_file' 194 cat ./*_trimming_report.txt > '$report_file'
196 #end if 195 #end if
196 && ls -lah
197 ]]></command> 197 ]]></command>
198 <inputs> 198 <inputs>
199 <!-- Input Parameters --> 199 <!-- Input Parameters -->
200 <conditional name="singlePaired"> 200 <conditional name="singlePaired">
201 <param name="sPaired" type="select" label="Is this library paired- or single-end?"> 201 <param name="sPaired" type="select" label="Is this library paired- or single-end?">
224 <expand macro="paired_adapter_trimming" /> 224 <expand macro="paired_adapter_trimming" />
225 </when> 225 </when>
226 </conditional> 226 </conditional>
227 227
228 <conditional name="params"> 228 <conditional name="params">
229 <param name="settingsType" type="select" label="Trim Galore! advanced settings" help="You can use the default settings or set custom values for any of Trim Galore!'s parameters."> 229 <param name="settingsType" type="select" label="Advanced settings" help="You can use the default settings or set custom values for any of Trim Galore!'s parameters.">
230 <option value="default">Use defaults</option> 230 <option value="default">Use defaults</option>
231 <option value="custom">Full parameter list</option> 231 <option value="custom">Full parameter list</option>
232 </param> 232 </param>
233 <when value="default" /> 233 <when value="default" />
234 <!-- Full/advanced params. --> 234 <!-- Full/advanced params. -->
259 259
260 </when> <!-- full --> 260 </when> <!-- full -->
261 </conditional> <!-- params --> 261 </conditional> <!-- params -->
262 262
263 <conditional name="rrbs"> 263 <conditional name="rrbs">
264 <param name="settingsType" type="select" label="RRBS specific settings"> 264 <param name="settingsType" type="select" label="RRBS specific settings" help="You can use the default settings or set custom values for any of Trim Galore!'s parameters.">
265 <option value="default">Use defaults (no RRBS)</option> 265 <option value="default">Use defaults (no RRBS)</option>
266 <option value="custom">Full parameter list</option> 266 <option value="custom">Full parameter list</option>
267 </param> 267 </param>
268 <when value="default" /> 268 <when value="default" />
269 <!-- Full/advanced params. --> 269 <!-- Full/advanced params. -->
272 label="Specifies that the input file was an MspI digested RRBS sample" /> 272 label="Specifies that the input file was an MspI digested RRBS sample" />
273 <param name="non_directional" type="boolean" truevalue="--non_directional" falsevalue="" checked="False" 273 <param name="non_directional" type="boolean" truevalue="--non_directional" falsevalue="" checked="False"
274 label="Screen quality-trimmed sequences for 'CAA' or 'CGA' at the start of the read and, if found, removes the first two basepairs" /> 274 label="Screen quality-trimmed sequences for 'CAA' or 'CGA' at the start of the read and, if found, removes the first two basepairs" />
275 </when> <!-- full --> 275 </when> <!-- full -->
276 </conditional> <!-- params --> 276 </conditional> <!-- params -->
277 <!--Trimming options-->
278 <conditional name="trimming">
279 <param name="settingsType" type="select" label="Trimming settings" help="You can use the default settings or set custom values for any of Trim Galore!'s parameters.">
280 <option value="default">Use defaults</option>
281 <option value="custom">Full parameter list</option>
282 </param>
283 <when value="default" />
284 <when value="custom">
285 <param argument="--hardtrim5" type="integer" min="1" optional="true" label="Hard-trimm 5' ends" help="Instead of performing adapter-/quality trimming, this option will simply hard-trim sequences to N bp at the 5'-end. Once hard-trimming of files is complete, it will exit" />
286 <param argument="--hardtrim3" type="integer" min="1" optional="true" label="Hard-trimm 3' ends" help="Instead of performing adapter-/quality trimming, this option will simply hard-trim sequences to N bp at the 3'-end. Once hard-trimming of files is complete, it will exit" />
287 <param argument="--clock" type="boolean" truevalue="--clock" falsevalue="" label="Mouse epigenetic clock mode" help="In this mode, reads are trimmed in a specific way that is currently used for the Mouse Epigenetic Clock"/>
288 <param argument="--polyA" type="boolean" truevalue="--polyA" falsevalue="" label="Remove polyA tails" help="This is a new, still experimental, trimming mode to identify and remove poly-A tails from sequences" />
289 </when>
290 </conditional>
277 </inputs> 291 </inputs>
278 292
279 <outputs> 293 <outputs>
280 <data format_source="input_singles" name="trimmed_reads_single" from_work_dir="input_1_trimmed.fq" label="${tool.name} on ${on_string}: trimmed reads"> 294 <data format_source="input_singles" name="trimmed_reads_single" from_work_dir="input_1_trimmed.fq" label="${tool.name} on ${on_string}: trimmed reads">
281 <filter>singlePaired['sPaired'] == "single"</filter> 295 <filter>singlePaired['sPaired'] == "single"</filter>
282 </data> 296 <filter>trimming['hardtrim3'] == '' and trimming['hardtrim5'] == ''</filter>
283 297 </data>
298
299 <data format_source="input_singles" name="hardtrim_reads_single" from_work_dir="input_1_hardtrim.fq" label="${tool.name} on ${on_string}: hard-trimmed reads">
300 <filter>singlePaired['sPaired'] == "single"</filter>
301 <filter>trimming['settingsType'] == "custom"</filter>
302 <filter>trimming['hardtrim3'] != '' or trimming['hardtrim5'] != ''</filter>
303 </data>
304
305 <!--Trimmed reads paired collection-->
284 <collection name="trimmed_reads_paired_collection" type="paired" label="${tool.name} on ${on_string}: paired reads"> 306 <collection name="trimmed_reads_paired_collection" type="paired" label="${tool.name} on ${on_string}: paired reads">
285 <data name="forward" format_source="input_mate_pairs['forward']" from_work_dir="input_1_val_1.fq" /> 307 <data name="forward" format_source="input_mate_pairs['forward']" from_work_dir="input_1_val_1.fq" />
286 <data name="reverse" format_source="input_mate_pairs['forward']" from_work_dir="input_2_val_2.fq" /> 308 <data name="reverse" format_source="input_mate_pairs['forward']" from_work_dir="input_2_val_2.fq" />
287 <filter>singlePaired['sPaired'] == "paired_collection"</filter> 309 <filter>singlePaired['sPaired'] == "paired_collection"</filter>
310 <filter>trimming['hardtrim3'] == '' and trimming['hardtrim5'] == ''</filter>
311 <filter>trimming['clock'] == False</filter>
288 </collection> 312 </collection>
289 313
314 <!--Unpaired reads collection-->
290 <collection name="trimmed_reads_unpaired_collection" type="paired" label="${tool.name} on ${on_string}: unpaired reads"> 315 <collection name="trimmed_reads_unpaired_collection" type="paired" label="${tool.name} on ${on_string}: unpaired reads">
291 <data name="forward" format_source="input_mate_pairs['forward']" from_work_dir="input_1_unpaired_1.fq" /> 316 <data name="forward" format_source="input_mate_pairs['forward']" from_work_dir="input_1_unpaired_1.fq" />
292 <data name="reverse" format_source="input_mate_pairs['forward']" from_work_dir="input_2_unpaired_2.fq" /> 317 <data name="reverse" format_source="input_mate_pairs['forward']" from_work_dir="input_2_unpaired_2.fq" />
293 <filter>params['settingsType'] == "custom"</filter> 318 <filter>params['settingsType'] == "custom"</filter>
294 <filter>params['retain_unpaired']['retain_unpaired_select'] == "retain_unpaired_output"</filter> 319 <filter>params['retain_unpaired']['retain_unpaired_select'] == "retain_unpaired_output"</filter>
295 <filter>singlePaired['sPaired'] == "paired_collection"</filter> 320 <filter>singlePaired['sPaired'] == "paired_collection"</filter>
321 <filter>trimming['hardtrim3'] == '' and trimming['hardtrim5'] == ''</filter>
296 </collection> 322 </collection>
323
324 <!--Hard-trimmed reads paired collection-->
325 <collection name="hardtrimmed_reads_paired_collection" type="paired" label="${tool.name} on ${on_string}: hard-trimmed paired reads">
326 <data name="forward" format_source="input_mate_pairs['forward']" from_work_dir="input_1_hardtrim.fq" />
327 <data name="reverse" format_source="input_mate_pairs['forward']" from_work_dir="input_2_hardtrim.fq" />
328 <filter>singlePaired['sPaired'] == "paired_collection"</filter>
329 <filter>trimming['settingsType'] == "custom"</filter>
330 <filter>trimming['hardtrim3'] or trimming['hardtrim5']</filter>
331 </collection>
332
333 <!--Mouse epigenetic reads paired collection-->
334 <collection name="mouse_reads_paired_collection" type="paired" label="${tool.name} on ${on_string}: MEC paired reads">
335 <data name="forward" format_source="input_mate_pairs['forward']" from_work_dir="input_1.clock_UMI.R1.fq" />
336 <data name="reverse" format_source="input_mate_pairs['forward']" from_work_dir="input_2.clock_UMI.R2.fq" />
337 <filter>singlePaired['sPaired'] == "paired_collection"</filter>
338 <filter>trimming['settingsType'] == "custom"</filter>
339 <filter>trimming['clock']</filter>
340 </collection>
341
297 342
298 <data format_source="input_mate1" name="trimmed_reads_pair1" from_work_dir="input_1_val_1.fq" 343 <data format_source="input_mate1" name="trimmed_reads_pair1" from_work_dir="input_1_val_1.fq"
299 label="${tool.name} on ${on_string}: trimmed reads pair 1"> 344 label="${tool.name} on ${on_string}: trimmed reads pair 1">
300 <filter>singlePaired['sPaired'] == "paired"</filter> 345 <filter>singlePaired['sPaired'] == "paired"</filter>
346 <filter>trimming['hardtrim3'] == '' and trimming['hardtrim5'] == ''</filter>
347 <filter>trimming['clock'] == False</filter>
301 </data> 348 </data>
302 349
303 <data format_source="input_mate2" name="trimmed_reads_pair2" from_work_dir="input_2_val_2.fq" 350 <data format_source="input_mate2" name="trimmed_reads_pair2" from_work_dir="input_2_val_2.fq"
304 label="${tool.name} on ${on_string}: trimmed reads pair 2"> 351 label="${tool.name} on ${on_string}: trimmed reads pair 2">
305 <filter>singlePaired['sPaired'] == "paired"</filter> 352 <filter>singlePaired['sPaired'] == "paired"</filter>
353 <filter>trimming['hardtrim3'] == '' and trimming['hardtrim5'] == ''</filter>
354 <filter>trimming['clock'] == False</filter>
306 </data> 355 </data>
307 356
308 <data format_source="input_mate1" name="unpaired_reads_1" from_work_dir="input_1_unpaired_1.fq" 357 <data format_source="input_mate1" name="unpaired_reads_1" from_work_dir="input_1_unpaired_1.fq"
309 label="${tool.name} on ${on_string}: unpaired reads (1)"> 358 label="${tool.name} on ${on_string}: unpaired reads (1)">
310 <filter>params['settingsType'] == "custom"</filter> 359 <filter>params['settingsType'] == "custom"</filter>
316 label="${tool.name} on ${on_string}: unpaired reads (2)"> 365 label="${tool.name} on ${on_string}: unpaired reads (2)">
317 <filter>params['settingsType'] == "custom"</filter> 366 <filter>params['settingsType'] == "custom"</filter>
318 <filter>params['retain_unpaired']['retain_unpaired_select'] == "retain_unpaired_output"</filter> 367 <filter>params['retain_unpaired']['retain_unpaired_select'] == "retain_unpaired_output"</filter>
319 <filter>singlePaired['sPaired'] == "paired"</filter> 368 <filter>singlePaired['sPaired'] == "paired"</filter>
320 </data> 369 </data>
370 <!--Hard-trimmed paired reads-->
371 <data format_source="input_mate1" name="hardtrimmed_reads_pair1" from_work_dir="input_1_hardtrim.fq"
372 label="${tool.name} on ${on_string}: hard-trimmed reads pair 1">
373 <filter>singlePaired['sPaired'] == "paired"</filter>
374 <filter>trimming['settingsType'] == 'custom'</filter>
375 <filter>trimming['hardtrim3'] or trimming['hardtrim5']</filter>
376 </data>
377
378 <data format_source="input_mate2" name="hardtrimmed_reads_pair2" from_work_dir="input_2_hardtrim.fq"
379 label="${tool.name} on ${on_string}: hard-trimmed reads pair 2">
380 <filter>singlePaired['sPaired'] == "paired"</filter>
381 <filter>trimming['settingsType'] == 'custom'</filter>
382 <filter>trimming['hardtrim3'] or trimming['hardtrim5']</filter>
383 </data>
384
385 <!--Mouse epigenetic mode paired reads-->
386 <data format_source="input_mate1" name="mec_reads_pair1" from_work_dir="input_1.clock_UMI.R1.fq"
387 label="${tool.name} on ${on_string}: MEC reads pair 1">
388 <filter>singlePaired['sPaired'] == "paired"</filter>
389 <filter>trimming['settingsType'] == 'custom'</filter>
390 <filter>trimming['clock']</filter>
391 </data>
392
393 <data format_source="input_mate2" name="mec_reads_pair2" from_work_dir="input_2.clock_UMI.R2.fq"
394 label="${tool.name} on ${on_string}: MEC reads pair 2">
395 <filter>singlePaired['sPaired'] == "paired"</filter>
396 <filter>trimming['settingsType'] == 'custom'</filter>
397 <filter>trimming['clock']</filter>
398 </data>
399
321 <data format="txt" name="report_file" label="${tool.name} on ${on_string}: report file"> 400 <data format="txt" name="report_file" label="${tool.name} on ${on_string}: report file">
322 <filter>params['settingsType'] == "custom"</filter> 401 <filter>params['settingsType'] == "custom"</filter>
323 <filter>params['report'] == True</filter> 402 <filter>params['report'] == True</filter>
324 </data> 403 </data>
325 </outputs> 404 </outputs>
326 405
327 <tests> 406 <tests>
328 <test> 407 <test expect_num_outputs="2">
329 <param name="input_singles" value="sanger_full_range_original_sanger.fastqsanger" ftype="fastqsanger" /> 408 <param name="input_singles" value="sanger_full_range_original_sanger.fastqsanger" ftype="fastqsanger" />
330 <param name="sPaired" value="single" /> 409 <param name="sPaired" value="single" />
331 <param name="settingsType" value="custom" /> 410 <param name="settingsType" value="custom" />
332 <param name="report" value="true" /> 411 <param name="report" value="true" />
333 <output name="trimmed_reads_single" file="sanger_full_range_results1.fastqsanger" ftype="fastqsanger"/> 412 <output name="trimmed_reads_single" file="sanger_full_range_results1.fastqsanger" ftype="fastqsanger"/>
334 <output name="report_file" file="sanger_full_range_report_results1.txt" ftype="txt" lines_diff="8" /> 413 <output name="report_file" file="sanger_full_range_report_results1.txt" ftype="txt" lines_diff="12" />
335 </test> 414 </test>
336 <test> 415 <test expect_num_outputs="2">
337 <param name="input_singles" value="sanger_full_range_original_sanger.fastq.gz" ftype="fastqsanger.gz" /> 416 <param name="input_singles" value="sanger_full_range_original_sanger.fastq.gz" ftype="fastqsanger.gz" />
338 <param name="sPaired" value="single" /> 417 <param name="sPaired" value="single" />
339 <param name="settingsType" value="custom" /> 418 <param name="settingsType" value="custom" />
340 <param name="report" value="true" /> 419 <param name="report" value="true" />
341 <output name="trimmed_reads_single" file="sanger_full_range_results1.fastq.gz" ftype="fastqsanger.gz" decompress="true" /> 420 <output name="trimmed_reads_single" file="sanger_full_range_results1.fastq.gz" ftype="fastqsanger.gz" decompress="true" />
342 <output name="report_file" file="sanger_full_range_report_results1gz.txt" ftype="txt" lines_diff="9" /> 421 <output name="report_file" file="sanger_full_range_report_results1gz.txt" ftype="txt" lines_diff="12" />
343 </test> 422 </test>
344 423
345 <test> 424 <test expect_num_outputs="1">
346 <param name="input_singles" value="sanger_full_range_original_sanger.fastqsanger" ftype="fastqsanger" /> 425 <param name="input_singles" value="sanger_full_range_original_sanger.fastqsanger" ftype="fastqsanger" />
347 <param name="sPaired" value="single" /> 426 <param name="sPaired" value="single" />
348 <param name="trimming_select" value="--illumina" /> 427 <param name="trimming_select" value="--illumina" />
349 <output name="trimmed_reads_single" file="sanger_full_range_results2.fastqsanger" ftype="fastqsanger"/> 428 <output name="trimmed_reads_single" file="sanger_full_range_results2.fastqsanger" ftype="fastqsanger"/>
350 </test> 429 </test>
351 <test> 430 <test expect_num_outputs="1">
352 <param name="input_singles" value="sanger_full_range_original_sanger.fastq.gz" ftype="fastqsanger.gz" /> 431 <param name="input_singles" value="sanger_full_range_original_sanger.fastq.gz" ftype="fastqsanger.gz" />
353 <param name="sPaired" value="single" /> 432 <param name="sPaired" value="single" />
354 <param name="trimming_select" value="--illumina" /> 433 <param name="trimming_select" value="--illumina" />
355 <output name="trimmed_reads_single" file="sanger_full_range_results2.fastq.gz" ftype="fastqsanger.gz" decompress="true" /> 434 <output name="trimmed_reads_single" file="sanger_full_range_results2.fastq.gz" ftype="fastqsanger.gz" decompress="true" />
356 </test> 435 </test>
357 436
358 <test> 437 <test expect_num_outputs="1">
359 <param name="input_singles" value="sanger_full_range_original_sanger.fastqsanger" ftype="fastqsanger" /> 438 <param name="input_singles" value="sanger_full_range_original_sanger.fastqsanger" ftype="fastqsanger" />
360 <param name="sPaired" value="single" /> 439 <param name="sPaired" value="single" />
361 <param name="adapter" value="AAAGAGC" /> 440 <param name="adapter" value="AAAGAGC" />
362 <output name="trimmed_reads_single" file="sanger_full_range_results3.fastqsanger" ftype="fastqsanger"/> 441 <output name="trimmed_reads_single" file="sanger_full_range_results3.fastqsanger" ftype="fastqsanger"/>
363 </test> 442 </test>
364 <test> 443 <test expect_num_outputs="1">
365 <param name="input_singles" value="sanger_full_range_original_sanger.fastq.gz" ftype="fastqsanger.gz" /> 444 <param name="input_singles" value="sanger_full_range_original_sanger.fastq.gz" ftype="fastqsanger.gz" />
366 <param name="sPaired" value="single" /> 445 <param name="sPaired" value="single" />
367 <param name="adapter" value="AAAGAGC" /> 446 <param name="adapter" value="AAAGAGC" />
368 <output name="trimmed_reads_single" file="sanger_full_range_results3.fastq.gz" ftype="fastqsanger.gz" decompress="true" /> 447 <output name="trimmed_reads_single" file="sanger_full_range_results3.fastq.gz" ftype="fastqsanger.gz" decompress="true" />
369 </test> 448 </test>
370 449
371 <test> 450 <test expect_num_outputs="3">
372 <param name="input_mate1" value="bwa-mem-fastq1.fq" ftype="fastqsanger" /> 451 <param name="input_mate1" value="bwa-mem-fastq1.fq" ftype="fastqsanger" />
373 <param name="input_mate2" value="bwa-mem-fastq2.fq" ftype="fastqsanger" /> 452 <param name="input_mate2" value="bwa-mem-fastq2.fq" ftype="fastqsanger" />
374 <param name="sPaired" value="paired" /> 453 <param name="sPaired" value="paired" />
375 <param name="settingsType" value="custom" /> 454 <param name="settingsType" value="custom" />
376 <param name="report" value="true" /> 455 <param name="report" value="true" />
377 <output name="trimmed_reads_pair1" file="paired_example_pair1_results2.fastqsanger" ftype="fastqsanger"/> 456 <output name="trimmed_reads_pair1" file="paired_example_pair1_results2.fastqsanger" ftype="fastqsanger"/>
378 <output name="trimmed_reads_pair2" file="paired_example_pair2_results2.fastqsanger" ftype="fastqsanger"/> 457 <output name="trimmed_reads_pair2" file="paired_example_pair2_results2.fastqsanger" ftype="fastqsanger"/>
379 <output name="report_file" file="paired_example_results2.txt" ftype="txt" lines_diff="24" /> 458 <output name="report_file" file="paired_example_results2.txt" ftype="txt" lines_diff="24" />
380 </test> 459 </test>
381 <test> 460 <test expect_num_outputs="3">
382 <param name="input_mate1" value="bwa-mem-fastq1.fq.gz" ftype="fastqsanger.gz" /> 461 <param name="input_mate1" value="bwa-mem-fastq1.fq.gz" ftype="fastqsanger.gz" />
383 <param name="input_mate2" value="bwa-mem-fastq2.fq.gz" ftype="fastqsanger.gz" /> 462 <param name="input_mate2" value="bwa-mem-fastq2.fq.gz" ftype="fastqsanger.gz" />
384 <param name="sPaired" value="paired" /> 463 <param name="sPaired" value="paired" />
385 <param name="settingsType" value="custom" /> 464 <param name="settingsType" value="custom" />
386 <param name="report" value="true" /> 465 <param name="report" value="true" />
387 <output name="trimmed_reads_pair1" file="paired_example_pair1_results2.fastq.gz" ftype="fastqsanger.gz" decompress="true" /> 466 <output name="trimmed_reads_pair1" file="paired_example_pair1_results2.fastq.gz" ftype="fastqsanger.gz" decompress="true" />
388 <output name="trimmed_reads_pair2" file="paired_example_pair2_results2.fastq.gz" ftype="fastqsanger.gz" decompress="true" /> 467 <output name="trimmed_reads_pair2" file="paired_example_pair2_results2.fastq.gz" ftype="fastqsanger.gz" decompress="true" />
389 <output name="report_file" file="paired_example_results2gz.txt" ftype="txt" lines_diff="24" /> 468 <output name="report_file" file="paired_example_results2gz.txt" ftype="txt" lines_diff="24" />
390 </test> 469 </test>
391 470
392 <test> 471 <test expect_num_outputs="7">
393 <param name="input_mate_pairs"> 472 <param name="input_mate_pairs">
394 <collection type="paired"> 473 <collection type="paired">
395 <element name="forward" value="bwa-mem-fastq1.fq" ftype="fastqsanger" /> 474 <element name="forward" value="bwa-mem-fastq1.fq" ftype="fastqsanger" />
396 <element name="reverse" value="bwa-mem-fastq2.fq" ftype="fastqsanger" /> 475 <element name="reverse" value="bwa-mem-fastq2.fq" ftype="fastqsanger" />
397 </collection> 476 </collection>
412 <output_collection name="trimmed_reads_unpaired_collection" type="paired"> 491 <output_collection name="trimmed_reads_unpaired_collection" type="paired">
413 <element name="forward" file="paired_collection_example_unpair1_results3.fastqsanger" ftype="fastqsanger"/> 492 <element name="forward" file="paired_collection_example_unpair1_results3.fastqsanger" ftype="fastqsanger"/>
414 <element name="reverse" file="paired_collection_example_unpair2_results3.fastqsanger" ftype="fastqsanger"/> 493 <element name="reverse" file="paired_collection_example_unpair2_results3.fastqsanger" ftype="fastqsanger"/>
415 </output_collection> 494 </output_collection>
416 </test> 495 </test>
417 <test> 496 <test expect_num_outputs="7">
418 <param name="input_mate_pairs"> 497 <param name="input_mate_pairs">
419 <collection type="paired"> 498 <collection type="paired">
420 <element name="forward" value="bwa-mem-fastq1.fq.gz" ftype="fastqsanger.gz" /> 499 <element name="forward" value="bwa-mem-fastq1.fq.gz" ftype="fastqsanger.gz" />
421 <element name="reverse" value="bwa-mem-fastq2.fq.gz" ftype="fastqsanger.gz" /> 500 <element name="reverse" value="bwa-mem-fastq2.fq.gz" ftype="fastqsanger.gz" />
422 </collection> 501 </collection>
437 <output_collection name="trimmed_reads_unpaired_collection" type="paired"> 516 <output_collection name="trimmed_reads_unpaired_collection" type="paired">
438 <element name="forward" file="paired_collection_example_unpair1_results3.fastq.gz" ftype="fastqsanger.gz" decompress="true" /> 517 <element name="forward" file="paired_collection_example_unpair1_results3.fastq.gz" ftype="fastqsanger.gz" decompress="true" />
439 <element name="reverse" file="paired_collection_example_unpair2_results3.fastq.gz" ftype="fastqsanger.gz" decompress="true" /> 518 <element name="reverse" file="paired_collection_example_unpair2_results3.fastq.gz" ftype="fastqsanger.gz" decompress="true" />
440 </output_collection> 519 </output_collection>
441 </test> 520 </test>
521 <!--Test hard-trim option-->
522 <test expect_num_outputs="2">
523 <param name="input_mate1" value="bwa-mem-fastq1.fq" ftype="fastqsanger" />
524 <param name="input_mate2" value="bwa-mem-fastq2.fq" ftype="fastqsanger" />
525 <param name="sPaired" value="paired" />
526 <conditional name="trimming">
527 <param name="settingsType" value="custom" />
528 <param name="hardtrim3" value="20"/>
529 </conditional>
530 <output name="hardtrimmed_reads_pair1" file="paired_hardtrimmed3_pair1_.fastqsanger" ftype="fastqsanger"/>
531 <output name="hardtrimmed_reads_pair1" file="paired_hardtrimmed3_pair2_.fastqsanger" ftype="fastqsanger"/>
532 </test>
533 <test expect_num_outputs="2">
534 <param name="input_mate1" value="bwa-mem-fastq1.fq" ftype="fastqsanger" />
535 <param name="input_mate2" value="bwa-mem-fastq2.fq" ftype="fastqsanger" />
536 <param name="sPaired" value="paired" />
537 <conditional name="trimming">
538 <param name="settingsType" value="custom" />
539 <param name="hardtrim5" value="20"/>
540 </conditional>
541 <output name="hardtrimmed_reads_pair1" file="paired_hardtrimmed5_pair1_.fastqsanger" ftype="fastqsanger"/>
542 <output name="hardtrimmed_reads_pair1" file="paired_hardtrimmed5_pair2_.fastqsanger" ftype="fastqsanger"/>
543 </test>
544
545 <!--Test mouse epigenetic clock option-->
546 <test expect_num_outputs="2">
547 <param name="input_mate1" value="bwa-mem-fastq1.fq" ftype="fastqsanger" />
548 <param name="input_mate2" value="bwa-mem-fastq2.fq" ftype="fastqsanger" />
549 <param name="sPaired" value="paired" />
550 <conditional name="trimming">
551 <param name="settingsType" value="custom" />
552 <param name="clock" value="true"/>
553 </conditional>
554 <output name="mec_reads_pair1" file="mec_reads_pair1.fastqsanger" ftype="fastqsanger"/>
555 <output name="mec_reads_pair2" file="mec_reads_pair2.fastqsanger" ftype="fastqsanger"/>
556 </test>
557 <!--Test polyA option-->
558 <test expect_num_outputs="2">
559 <param name="input_mate1" value="bwa-mem-fastq1.fq" ftype="fastqsanger" />
560 <param name="input_mate2" value="bwa-mem-fastq2.fq" ftype="fastqsanger" />
561 <param name="sPaired" value="paired" />
562 <conditional name="trimming">
563 <param name="settingsType" value="custom" />
564 <param name="polyA" value="true"/>
565 </conditional>
566 <output name="trimmed_reads_pair1" file="trimmed_polyA_reads_pair1.fastqsanger" ftype="fastqsanger"/>
567 <output name="trimmed_reads_pair1" file="trimmed_polyA_reads_pair2.fastqsanger" ftype="fastqsanger"/>
568 </test>
442 </tests> 569 </tests>
443 <help><![CDATA[ 570 <help><![CDATA[
444 **What it does** 571 **What it does**
445 572
446 `Trim Galore!`_ is a wrapper script to automate quality and adapter trimming as well as quality control, with some added functionality to remove biased methylation positions for RRBS sequence files (for directional, non-directional (or paired-end) sequencing). It's main features are: 573 `Trim Galore!`_ is a wrapper script to automate quality and adapter trimming as well as quality control, with some added functionality to remove biased methylation positions for RRBS sequence files (for directional, non-directional (or paired-end) sequencing). It's main features are:
450 * For any kind of FASTQ file other than MspI-digested RRBS, Trim Galore! can perform single-pass adapter and quality trimming 577 * For any kind of FASTQ file other than MspI-digested RRBS, Trim Galore! can perform single-pass adapter and quality trimming
451 * The Phred quality of basecalls and the stringency for adapter removal can be specified individually 578 * The Phred quality of basecalls and the stringency for adapter removal can be specified individually
452 * Trim Galore! can remove sequences if they become too short during the trimming process. For paired-end files Trim Galore! removes entire sequence pairs if one (or both) of the two reads became shorter than the set length cutoff. Reads of a read-pair that are longer than a given threshold but for which the partner read has become too short can optionally be written out to single-end files. This ensures that the information of a read pair is not lost entirely if only one read is of good quality 579 * Trim Galore! can remove sequences if they become too short during the trimming process. For paired-end files Trim Galore! removes entire sequence pairs if one (or both) of the two reads became shorter than the set length cutoff. Reads of a read-pair that are longer than a given threshold but for which the partner read has become too short can optionally be written out to single-end files. This ensures that the information of a read pair is not lost entirely if only one read is of good quality
453 * Trim Galore! can trim paired-end files by 1 additional bp from the 3' end of all reads to avoid problems with invalid alignments with Bowtie 1 580 * Trim Galore! can trim paired-end files by 1 additional bp from the 3' end of all reads to avoid problems with invalid alignments with Bowtie 1
454 581
455 .. _Trim Galore!: http://www.bioinformatics.babraham.ac.uk/projects/trim_galore/
456 582
457 It is developed by Felix Krueger at the Babraham Institute. 583 It is developed by Felix Krueger at the Babraham Institute.
458 584
459 ---- 585 ----
460 586
589 * **Screen quality-trimmed sequences for 'CAA' or 'CGA' at the start of the read and, if found, removes the first two basepairs** 715 * **Screen quality-trimmed sequences for 'CAA' or 'CGA' at the start of the read and, if found, removes the first two basepairs**
590 716
591 | Selecting this option for non-directional RRBS libraries will screen quality-trimmed sequences for 'CAA' or 'CGA' at the start of the read and, if found, removes the first two basepairs. Like with the option '--rrbs' this avoids using cytosine positions that were filled-in during the end-repair step. '--non_directional' requires '--rrbs' to be specified as well. 717 | Selecting this option for non-directional RRBS libraries will screen quality-trimmed sequences for 'CAA' or 'CGA' at the start of the read and, if found, removes the first two basepairs. Like with the option '--rrbs' this avoids using cytosine positions that were filled-in during the end-repair step. '--non_directional' requires '--rrbs' to be specified as well.
592 | 718 |
593 | *option --non_directional* 719 | *option --non_directional*
720
721 ----
722
723 **Trim specific seetings**
724
725 * **Hard-trimming mode**
726
727 | Instead of performing adapter-/quality trimming, this option will simply hard-trim sequences to N bp at the 5' or 3' -end.
728 |
729 | *options -hardtrim5 and -hardtrim3*
730
731 * **Mouse Epigenetic Clock mode**
732
733 | In this mode, reads are trimmed in a specific way that is currently used for the Mouse Epigenetic Clock (see here: `Multi-tissue DNA methylation age predictor in mouse`_). Following this, Trim Galore will exit.
734 |
735 | In it's current implementation, the dual-UMI RRBS reads come in the following format:
736 |
737 | Read 1 5' UUUUUUUU CAGTA FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF TACTG UUUUUUUU 3'
738 | Read 2 3' UUUUUUUU GTCAT FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF ATGAC UUUUUUUU 5'
739 |
740 | Where UUUUUUUU is a random 8-mer unique molecular identifier (UMI), CAGTA is a constant region, and FFFFFFF... is the actual RRBS-Fragment to be sequenced. The UMIs for Read 1 (R1) and Read 2 (R2), as well as the fixed sequences (F1 or F2), are written into the read ID and removed from the actual sequence.
741 |
742 | *option --clock*
743
744 * **PolyA mode**
745
746 | This is a new, still experimental, trimming mode to identify and remove poly-A tails from sequences. When selected, Trim Galore attempts to identify from the first supplied sample whether sequences contain more often a stretch of either 'AAAAAAAAAA' or 'TTTTTTTTTT'. This determines if Read 1 of a paired-end end file, or single-end files, are trimmed for PolyA or PolyT. In case of paired-end sequencing, Read2 is trimmed for the complementary base from the start of the reads.
747 |
748 | PLEASE NOTE: The poly-A trimming mode expects that sequences were both adapter and quality trimmed before looking for Poly-A tails, and it is the user's responsibility to carry out an initial round of trimming.
749 |
750 | *option --polyA*
751
752 * **Amplicon mode**
753
754 | This is a special mode of operation for paired-end data, such as required for the IMPLICON method, where a UMI sequence is getting transferred from the start of Read 2 to the readID of both reads. Following this, Trim Galore will exit.
755 |
756 | In it's current implementation, the UMI carrying reads come in the following format:
757 |
758 | Read 1 5' FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF 3'
759 | Read 2 3' UUUUUUUUFFFFFFFFFFFFFFFFFFFFFFFFFFFF 5'
760 |
761 | Where UUUUUUUU is a random 8-mer unique molecular identifier (UMI) and FFFFFFF... is the actual fragment to be sequenced.
762 |
763 | *option --amplicon*
764
765 .. _Trim Galore!: http://www.bioinformatics.babraham.ac.uk/projects/trim_galore/
766 .. _Multi-tissue DNA methylation age predictor in mouse: https://genomebiology.biomedcentral.com/articles/10.1186/s13059-017-1203-5
767
594 ]]></help> 768 ]]></help>
595 <citations></citations> 769 <expand macro="citations" />
596 </tool> 770 </tool>