comparison stacks_ustacks.xml @ 0:7e5a174bc201 draft

planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/stacks2 commit b395fa36fa826e26085820ba3a9faacaeddcb460
author iuc
date Mon, 01 Jul 2019 10:57:49 -0400
parents
children 21d2aa544835
comparison
equal deleted inserted replaced
-1:000000000000 0:7e5a174bc201
1 <tool id="stacks2_ustacks" name="Stacks2: ustacks" profile="@PROFILE@" version="@STACKS_VERSION@+galaxy@WRAPPER_VERSION@">
2 <description>Identify unique stacks</description>
3 <macros>
4 <import>macros.xml</import>
5 </macros>
6 <expand macro="requirements"/>
7 <expand macro="version_cmd"/>
8 <command detect_errors="aggressive"><![CDATA[
9 @FASTQ_INPUT_FUNCTIONS@
10
11 mkdir stacks_inputs stacks_outputs
12
13 &&
14
15 #set $ID=1
16 #for $sample in $input_type.fqinputs
17 #set ($create_links, $data_path, $name, $inputype) = $fastq_input_foo($sample, "forward", ".1")
18 $create_links
19
20 ustacks
21
22 -f '$data_path'
23 -i $ID
24 --name $name
25 -m $m
26 -M $M
27 #if $N
28 -N $N
29 #end if
30 -p \${GALAXY_SLOTS:-1}
31 -t $inputype
32 $R
33 $H
34
35 ## Assembly
36 $assembly_options.keep_high_cov
37 --high_cov_thres $assembly_options.high_cov_thres
38 $assembly_options.d
39 --max_locus_stacks $assembly_options.max_locus_stacks
40 #if str($assembly_options.k_len)
41 --k_len $assembly_options.k_len
42 #end if
43
44 @GAP_OPTIONS@
45
46 ## snp_model
47 #if str( $snp_options.select_model.model_type) == "bounded"
48 --model_type bounded
49 --bound_low $snp_options.select_model.bound_low
50 --bound_high $snp_options.select_model.bound_high
51 --alpha $snp_options.select_model.alpha
52 #else if str( $snp_options.select_model.model_type) == "snp"
53 --model_type snp
54 --alpha $snp_options.select_model.alpha
55 #else
56 --model_type fixed
57 --bc_err_freq $bc_err_freq
58 #end if
59
60 -o stacks_outputs
61
62 @TEE_APPEND_LOG@
63
64 #set $ID=$ID+1
65 #end for
66 @CAT_LOG_TO_STDERR@
67 ## If input is in gz format, stacks will output gzipped files (no option to control this)
68 #if $inputype.startswith('gz')
69 && gunzip stacks_outputs/*.gz
70 #end if
71 ]]></command>
72
73 <inputs>
74 <expand macro="fastq_input" help="Single end data or forward reads. If a paired list is provided only the forward reads are used in ustacks"/>
75
76 <param argument="-m" type="integer" value="3" label="Minimum depth of coverage required to create a stack"/>
77 <param argument="-M" type="integer" value="2" label="Maximum distance (in nucleotides) allowed between stacks"/>
78 <param argument="-N" type="integer" value="" optional="true" label="Maximum distance allowed to align secondary reads to primary stacks" help="(default: M + 2)"/>
79 <param argument="-R" type="boolean" checked="false" truevalue="-R" falsevalue="" label="Retain unused reads" />
80 <param argument="-H" type="boolean" checked="false" truevalue="-H" falsevalue="" label="Disable calling haplotypes from secondary reads" />
81 <section name="assembly_options" title="SNP Model Options (ustacks options)" expanded="True">
82 <param argument="--keep_high_cov" type="boolean" checked="false" truevalue="--keep_high_cov" falsevalue="" label="Disable the algorithm that removes highly-repetitive stacks and nearby errors. " />
83 <param argument="-d" type="boolean" checked="false" truevalue="-d" falsevalue="" label="Enable the Deleveraging algorithm, used for resolving over merged tags" />
84 <param argument="--high_cov_thres" type="float" min="0.0" value="3.0" label="Highly-repetitive stacks threshold" help="in standard deviation units"/>
85 <param argument="--max_locus_stacks" type="integer" value="3" label="Maximum number of stacks at a single de novo locus"/>
86 <param argument="--k_len" type="integer" value="" min="7" max="31" optional="true" label="K-mer size for matching between alleles and loci (automatically calculated by default)"/>
87 </section>
88 <expand macro="gap_options"/>
89
90 <!-- SNP Model options -->
91 <section name="snp_options" title="SNP Model Options (ustacks options)" expanded="False">
92 <expand macro="snp_options_full"/>
93 </section>
94 <expand macro="in_log"/>
95 </inputs>
96
97 <outputs>
98 <expand macro="out_log"/>
99 <expand macro="ustacks_outputs_macro"/>
100 </outputs>
101
102 <tests>
103 <!-- paired list, default options, test for file equality -->
104 <test>
105 <param name="input_type|input_type_select" value="paired"/>
106 <param name="input_type|fqinputs">
107 <collection type="list:paired">
108 <element name="PopA_01">
109 <collection type="paired">
110 <element name="forward" value="demultiplexed/PopA_01.1.fq" ftype="fastqsanger" />
111 <element name="reverse" value="demultiplexed/PopA_01.2.fq" ftype="fastqsanger"/>
112 </collection>
113 </element>
114 <element name="PopA_02">
115 <collection type="paired">
116 <element name="forward" value="demultiplexed/PopA_02.1.fq" ftype="fastqsanger" />
117 <element name="reverse" value="demultiplexed/PopA_02.2.fq" ftype="fastqsanger"/>
118 </collection>
119 </element>
120 </collection>
121 </param>
122 <param name="add_log" value="yes" />
123 <output name="output_log"><assert_contents><has_text text="done." /></assert_contents></output>
124 <output_collection name="tabs" type="list" count="6">
125 <element name="PopA_01.tags" ftype="tabular" file="ustacks/PopA_01.tags.tsv" lines_diff="2"/>
126 <element name="PopA_01.snps" ftype="tabular" file="ustacks/PopA_01.snps.tsv" lines_diff="2"/>
127 <element name="PopA_01.alleles" ftype="tabular" file="ustacks/PopA_01.alleles.tsv" lines_diff="2"/>
128 <element name="PopA_02.tags" ftype="tabular" file="ustacks/PopA_02.tags.tsv" lines_diff="2"/>
129 <element name="PopA_02.snps" ftype="tabular" file="ustacks/PopA_02.snps.tsv" lines_diff="2"/>
130 <element name="PopA_02.alleles" ftype="tabular" file="ustacks/PopA_02.alleles.tsv" lines_diff="2"/>
131 </output_collection>
132 </test>
133 <!-- manual selected list of elements + default args, test for file equality -->
134 <test>
135 <param name="input_type|input_type_select" value="single"/>
136 <param name="input_type|fqinputs" value="demultiplexed/PopA_01.1.fq,demultiplexed/PopA_02.1.fq" ftype="fastqsanger" />
137 <param name="add_log" value="yes" />
138 <output name="output_log" ftype="txt"><assert_contents><has_text text="ustacks is done."/></assert_contents></output>
139 <output_collection name="tabs" count="6">
140 <element name="PopA_01.tags"><assert_contents><has_text text="generated on " /></assert_contents></element>
141 <element name="PopA_01.snps"><assert_contents><has_text text="generated on " /></assert_contents></element>
142 <element name="PopA_01.alleles"><assert_contents><has_text text="generated on " /></assert_contents></element>
143 <element name="PopA_02.tags"><assert_contents><has_text text="generated on " /></assert_contents></element>
144 <element name="PopA_02.snps"><assert_contents><has_text text="generated on " /></assert_contents></element>
145 <element name="PopA_02.alleles"><assert_contents><has_text text="generated on " /></assert_contents></element>
146 </output_collection>
147 </test>
148 <!-- manual selected list of elements + non-default short args, test for file presence -->
149 <test>
150 <param name="input_type|input_type_select" value="single"/>
151 <param name="input_type|fqinputs" value="demultiplexed/PopA_01.1.fq,demultiplexed/PopA_02.1.fq" ftype="fastqsanger" />
152 <param name="-m" value="2" />
153 <param name="-M" value="3" />
154 <param name="-N" value="4"/>
155 <param name="-R" value="-R" />
156 <param name="-H" value="-H" />
157 <param name="add_log" value="yes" />
158 <assert_command>
159 <has_text text="-m 2" />
160 <has_text text="-M 3" />
161 <has_text text="-N 5" />
162 <has_text text="-R" />
163 <has_text text="-H" />
164 </assert_command>
165 <output name="output_log" ftype="txt"><assert_contents><has_text text="ustacks is done."/></assert_contents></output>
166 <output_collection name="tabs" count="6">
167 <element name="PopA_01.tags"><assert_contents><has_text text="generated on " /></assert_contents></element>
168 <element name="PopA_01.snps"><assert_contents><has_text text="generated on " /></assert_contents></element>
169 <element name="PopA_01.alleles"><assert_contents><has_text text="generated on " /></assert_contents></element>
170 <element name="PopA_02.tags"><assert_contents><has_text text="generated on " /></assert_contents></element>
171 <element name="PopA_02.snps"><assert_contents><has_text text="generated on " /></assert_contents></element>
172 <element name="PopA_02.alleles"><assert_contents><has_text text="generated on " /></assert_contents></element>
173 </output_collection>
174 </test>
175 <!-- paired list, non-default model options, disabled gapped alignment, test for file presence -->
176 <test>
177 <param name="input_type|input_type_select" value="paired"/>
178 <param name="input_type|fqinputs">
179 <collection type="list:paired">
180 <element name="PopA_01">
181 <collection type="paired">
182 <element name="forward" value="demultiplexed/PopA_01.1.fq" ftype="fastqsanger" />
183 <element name="reverse" value="demultiplexed/PopA_01.2.fq" ftype="fastqsanger"/>
184 </collection>
185 </element>
186 <element name="PopA_02">
187 <collection type="paired">
188 <element name="forward" value="demultiplexed/PopA_02.1.fq" ftype="fastqsanger" />
189 <element name="reverse" value="demultiplexed/PopA_02.2.fq" ftype="fastqsanger"/>
190 </collection>
191 </element>
192 </collection>
193 </param>
194 <conditional name="select_model">
195 <param name="model_type" value="snp"/>
196 <param name="alpha" value="0.1"/>
197 <param name="bound_low" value="0.1"/>
198 <param name="bound_high" value="0.5"/>
199 <param name="bc_err_freq" value="0.1"/>
200 </conditional>
201 <param name="gapped|use_gapped" value="no" />
202 <param name="add_log" value="yes" />
203 <assert_command>
204 <has_text text="--model_type bounded" />
205 <has_text text="--alpha 0.1" />
206 <has_text text="--bound_low 0.1" />
207 <has_text text="--bound_high 0.5" />
208 <has_text text="--bc_err_freq 0.1" />
209 <has_text text="--disable-gapped" />
210 </assert_command>
211 <output name="output_log" ftype="txt"><assert_contents><has_text text="ustacks is done."/></assert_contents></output>
212 <output_collection name="tabs" count="6">
213 <element name="PopA_01.tags"><assert_contents><has_text text="generated on " /></assert_contents></element>
214 <element name="PopA_01.snps"><assert_contents><has_text text="generated on " /></assert_contents></element>
215 <element name="PopA_01.alleles"><assert_contents><has_text text="generated on " /></assert_contents></element>
216 <element name="PopA_02.tags"><assert_contents><has_text text="generated on " /></assert_contents></element>
217 <element name="PopA_02.snps"><assert_contents><has_text text="generated on " /></assert_contents></element>
218 <element name="PopA_02.alleles"><assert_contents><has_text text="generated on " /></assert_contents></element>
219 </output_collection>
220 </test>
221 <!-- list of fwd reads, nondefault assembly and gapped alignment options, test for file presence -->
222 <test>
223 <param name="input_type|input_type_select" value="paired"/>
224 <param name="input_type|fqinputs">
225 <collection type="list">
226 <element name="PopA_01" value="demultiplexed/PopA_01.1.fq" ftype="fastqsanger" />
227 <element name="PopA_02" value="demultiplexed/PopA_02.1.fq" ftype="fastqsanger"/>
228 </collection>
229 </param>
230 <param name="assembly_options|keep_high_cov" value="--keep-high-cov"/>
231 <param name="assembly_options|d" value="-d" />
232 <param name="assembly_options|high_cov_thres" value="2.0"/>
233 <param name="assembly_options|max_locus_stacks" value="4" />
234 <param name="assembly_options|k_len" value="12"/>
235 <param name="gapped|use_gapped" value="yes" />
236 <param name="gapped|max_gaps" value="3" />
237 <param name="gapped|min_aln_len" value="0.7"/>
238 <param name="add_log" value="yes" />
239 <assert_command>
240 <has_text text="--keep_high_cov" />
241 <has_text text="-d" />
242 <has_text text="--high_cov_thres 2.0" />
243 <has_text text="--max_locus_stacks 4" />
244 <has_text text="--k_len 12" />
245 <has_text text="--max_gaps 3" />
246 <has_text text="--min_aln_len 3" />
247 </assert_command>
248 <output name="output_log" ftype="txt"><assert_contents><has_text text="ustacks is done."/></assert_contents></output>
249 <output_collection name="tabs" count="6">
250 <element name="PopA_01.tags"><assert_contents><has_text text="generated on " /></assert_contents></element>
251 <element name="PopA_01.snps"><assert_contents><has_text text="generated on " /></assert_contents></element>
252 <element name="PopA_01.alleles"><assert_contents><has_text text="generated on " /></assert_contents></element>
253 <element name="PopA_02.tags"><assert_contents><has_text text="generated on " /></assert_contents></element>
254 <element name="PopA_02.snps"><assert_contents><has_text text="generated on " /></assert_contents></element>
255 <element name="PopA_02.alleles"><assert_contents><has_text text="generated on " /></assert_contents></element>
256 </output_collection>
257 </test>
258 </tests>
259
260 <help>
261 <![CDATA[
262 .. class:: infomark
263
264 **What it does**
265
266 The unique stacks program will take as input a set of short-read sequences and align them into exactly-matching stacks. Comparing the stacks it will form a set of loci and detect SNPs at each locus using a maximum likelihood framework
267
268 --------
269
270 **Input files**
271
272 One or more FASTQ, FASTA files. Can be given by selecting them manually, as dataset list, or paired dataset list. Note, for the latter ustacks only uses the forward reads -- reverse reads are incorporated in tsv2bam.
273
274 **Output files**
275
276 - XXX.tags.tsv file:
277
278 See `Stacks output description <http://catchenlab.life.illinois.edu/stacks/manual/#files>`_
279
280 Notes: For the tags file, each stack will start in the file with a consensus sequence for the entire stack followed by the flags for that stack. Then, each individual read that was merged into that stack will follow. The next stack will start with another consensus sequence.
281
282
283 - XXX.snps.tsv file:
284
285 See `Stacks output description <http://catchenlab.life.illinois.edu/stacks/manual/#files>`_
286
287 Notes: If a stack has two SNPs called within it, then there will be two lines in this file listing each one.
288
289
290 - XXX.alleles.tsv file:
291
292 See `Stacks output description <http://catchenlab.life.illinois.edu/stacks/manual/#files>`_
293
294 @STACKS_INFOS@
295 ]]>
296 </help>
297 <expand macro="citation" />
298 </tool>