comparison chopper.xml @ 0:b248113ccb9d draft

planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/main/tools/chopper/ commit 56d3f713ca5685bb56f65386c224fdf54d443ea6
author iuc
date Wed, 24 Sep 2025 11:53:42 +0000
parents
children 885c104a6667
comparison
equal deleted inserted replaced
-1:000000000000 0:b248113ccb9d
1 <tool id="chopper" name="Chopper" version="@TOOL_VERSION@+galaxy@VERSION_SUFFIX@" profile="23.2">
2 <description>Filtering and trimming of long reads.</description>
3 <macros>
4 <token name="@TOOL_VERSION@">0.11.0</token>
5 <token name="@VERSION_SUFFIX@">0</token>
6 </macros>
7 <requirements>
8 <requirement type="package" version="@TOOL_VERSION@">chopper</requirement>
9 </requirements>
10 <version_command>chopper --version</version_command>
11 <command detect_errors="exit_code"><![CDATA[
12 chopper
13
14 --input $input
15
16 #if $contam
17 --contam $contam
18 #end if
19
20 #if $option_params.quality
21 --quality $option_params.quality.value
22 #end if
23
24 #if $option_params.maxqual
25 --maxqual $option_params.maxqual.value
26 #end if
27
28 #if $option_params.minlength
29 --minlength $option_params.minlength.value
30 #end if
31
32 #if $option_params.maxlength
33 --maxlength $option_params.maxlength.value
34 #end if
35
36 #if $option_params.headcrop
37 --headcrop $option_params.headcrop.value
38 #end if
39
40 #if $option_params.tailcrop
41 --tailcrop $option_params.tailcrop.value
42 #end if
43
44 #if $option_params.mingc
45 --mingc $option_params.mingc.value
46 #end if
47
48 #if $option_params.maxgc
49 --maxgc $option_params.maxgc.value
50 #end if
51
52 ##output capture
53 #if $output_params.inverse == "yes"
54 $output_params.inverse
55 #end if
56
57 #if $output_params.gzip == "no"
58 > $fq_filt
59 #else
60 | gzip > $fq_filt_gz
61 #end if
62
63 ]]></command>
64 <inputs>
65 <param argument="--input" type="data" label="FASTQ file to check" format="fastq,fastq.gz,fastqsanger.gz,fastqsanger" />
66 <param argument="--contam" type="data" format="fasta" optional="True" label="Reference FASTA" help="FASTA file with reference to check potential contaminants against."/>
67
68 <section name="option_params" title="Optional Parameters" expanded="True">
69 <param argument="--quality" type="integer" label="Minimal quality score" value="0" min="0" max="60" help="Sets a minimum Phred average quality score."/>
70 <param argument="--maxqual" type="integer" label="Maximal quality score" value="60" min="0" max="60" help="Sets a maximum Phred average quality score."/>
71 <param argument="--minlength" type="integer" label="Sets a minimum read length" value="1" min="1" help="Minimal length of read to keep." optional="True"/>
72 <param argument="--maxlength" type="integer" label="Sets a maximum read length" help="Maximal length of read to keep" optional="True"/>
73 <param argument="--headcrop" type="integer" optional="True" label="Headcrop" value="0" min="0" help="Trim N nucleotides from the start of a read."/>
74 <param argument="--tailcrop" type="integer" optional="True" label="Tailcrop" value="0" min="0" help="Trim N nucleotides from the end of a read."/>
75 <param argument="--mingc" type="float" optional="True" label="Minimum GC content" value="0.0" min="0.0" max="1.0" help="Sets a minimum GC content for reads to keep."/>
76 <param argument="--maxgc" type="float" optional="True" label="Maximum GC content" value="1.0" min="0.0" max="1.0" help="Sets a maximum GC content for reads to keep."/>
77 <param argument="--trim" type="integer" label="Q-score cutoff to trim read ends" value="0" min="0" max="60" help="Takes a quality score and will trim the ends of the reads if they are below the specified cut-off (window-size = 1)."/>
78 </section>
79
80 <section name="output_params" title="Output Parameters" expanded="False">
81 <param argument="--inverse" type="boolean" checked="false" truevalue="--inverse" falsevalue="" label="Output the opposite of the normal results" help="Reverse the output results (aka, the 'failed reads')"/>
82 <param name="gzip" type="boolean" checked="true" truevalue="yes" falsevalue="no" label="Gzip output data" help="Set to 'no' to NOT gzip the output file [default gzip output]."/>
83 </section>
84 </inputs>
85
86 <outputs>
87 <data name="fq_filt_gz" format="fastq.gz" label="${tool.name} on ${input.name} ($on_string), gzipped" >
88 <filter> output_params['gzip'] is True </filter>
89 </data>
90 <data name="fq_filt" format="fastq" label="${tool.name} on ${input.name} ($on_string)" >
91 <filter> output_params['gzip'] is False </filter>
92 </data>
93 </outputs>
94
95 <tests>
96 <test expect_num_outputs="1">
97 <param name="input" value="other-test.fastq"/>
98 <section name="output_params">
99 <param name="gzip" value="false"/>
100 </section>
101 <output name="fq_filt">
102 <assert_contents>
103 <has_text text="@35febf09-dcbc-424c-987e-9f3f80fe73a5"/>
104 <has_text text="@3fda06e9-62ef-4448-9993-b90124a793d5"/>
105 <has_text text="@19d9337f-4fb6-46e5-b484-14d05f562506"/>
106 </assert_contents>
107 </output>
108 </test>
109 <test expect_num_outputs="1">
110 <param name="input" value="other-test.fastq"/>
111 <param name="contam" value="random_contam.fa"/>
112 <output name="fq_filt" ftype="fastq.gz" decompress="true"> <!-- file="out2.fq.gz"/> -->
113 <assert_contents>
114 <has_text text="@35febf09-dcbc-424c-987e-9f3f80fe73a5"/>
115 <has_text text="@3fda06e9-62ef-4448-9993-b90124a793d5"/>
116 <has_text text="@19d9337f-4fb6-46e5-b484-14d05f562506"/>
117 </assert_contents>
118 </output>
119 </test>
120 <test expect_num_outputs="1">
121 <param name="input" value="testGC.fastq"/>
122 <section name="option_params">
123 <param name="mingc" value="0.3"/>
124 <param name="maxgc" value="0.8"/>
125 </section>
126 <section name="output_params">
127 <param name="gzip" value="false"/>
128 </section>
129 <output name="fq_filt" >
130 <assert_contents>
131 <not_has_text text='@GC20'/>
132 <not_has_text text='@GC0'/>
133 <not_has_text text='@GC100'/>
134 <has_text text='@GC50'/>
135 <has_text text='@GC80'/>
136 </assert_contents>
137 </output>
138 </test>
139 </tests>
140 <help><![CDATA[
141 **Chopper**
142
143 Rust implementation of NanoFilt+NanoLyse, both originally written in Python. This tool, intended for long read sequencing such as PacBio or ONT, filters and trims a fastq file.
144 Filtering is done on average read quality and minimal or maximal read length, and applying a headcrop (start of read) and tailcrop (end of read) while printing the reads passing the filter.
145
146 Compared to the Python implementation the scope is to deliver the same results, almost the same functionality, at much faster execution times. At the moment this tool does not support filtering using a sequencing_summary file.
147
148 **More Information**
149
150 - **Official Repository**: `Chopper on GitHub`_
151
152 .. _Chopper on GitHub: https://github.com/wdecoster/chopper
153
154 ]]></help>
155 <citations>
156 <citation type="doi">10.1093/bioinformatics/btad311</citation>
157 </citations>
158 </tool>