comparison metamlst.xml @ 0:d1df295495a9 draft

"planemo upload for repository https://github.com/quadram-institute-bioscience/galaxy-tools/tree/master/tools/metamlst commit 041ede79a8b699b00b1106cc82a5efe3c90c9876-dirty"
author thanhlv
date Wed, 23 Feb 2022 10:17:46 +0000
parents
children 4d3e54bace61
comparison
equal deleted inserted replaced
-1:000000000000 0:d1df295495a9
1 <tool id="metamlst" name="metamlst" version="@VERSION@">
2 <description> performs an in-silico Multi Locus Sequence Typing (MLST) Analysis on metagenomic samples</description>
3 <macros>
4 <token name="@VERSION@">1.2.2</token>
5 </macros>
6 <requirements>
7 <requirement type="package" version="@VERSION@">metamlst</requirement>
8 </requirements>
9 <version_command>metamlst.py --version | head -n 1 | cut -f 2</version_command>
10 <command detect_errors="exit_code"><![CDATA[
11 #import re
12 ## Link in the input files, so bowtie2 can tell their type
13 #set compressed="False"
14 #set reads_are_fastq = True
15 #if str($library.type) == 'paired':
16 #set name_1 = re.sub('[^\w\-\s]', '_', str($library.input_1.element_identifier))
17 #set name_2 = re.sub('[^\w\-\s]', '_', str($library.input_2.element_identifier))
18 #if $library.input_1.is_of_type("fastq.gz", "fastqsanger.gz"):
19 #set read1 = $name_1 + '.fastq.gz'
20 #set compressed = "GZ"
21 #else if $library.input_1.is_of_type("fastq.bz2", "fastqsanger.bz2"):
22 #set read1 = $name_1 + '.fastq.bz2'
23 #set compressed = "BZ2"
24 #else if $library.input_1.is_of_type('fasta'):
25 #set reads_are_fastq = False
26 #set read1 = $name_1 + '.fasta'
27 #else:
28 #set read1 = $name_1 + '.fastq'
29 #end if
30 ln -f -s '${library.input_1}' ${read1} &&
31
32 #if $library.input_2.is_of_type("fastq.gz", "fastqsanger.gz"):
33 #set read2 = $name_2 + '.fastq.gz'
34 #set compressed = "GZ"
35 #else if $library.input_2.is_of_type("fastq.bz2", "fastqsanger.bz2"):
36 #set read2 = $name_1 + '.fastq.bz2'
37 #set compressed = "BZ2"
38 #else if $library.input_2.is_of_type('fasta'):
39 #set read2 = $name_1 + '.fasta'
40 #else:
41 #set read2 = $name_1 + '.fastq'
42 #end if
43 ln -f -s '${library.input_2}' ${read2} &&
44 #else if str($library.type) == 'paired_collection':
45 #set pe_input_1 = $library.input_1.forward
46 #set pe_input_2 = $library.input_1.reverse
47 #set name_1 = re.sub('[^\w\-\s]', '_', str($library.pe_input_1.name)) + "_1"
48 #set name_2 = re.sub('[^\w\-\s]', '_', str($library.pe_input_2.name)) + "_2"
49 #if $library.input_1.forward.is_of_type("fastq.gz", "fastqsanger.gz"):
50 #set read1 = $name_1 + '.fastq.gz'
51 #set compressed = "GZ"
52 #else if $library.input_1.forward.is_of_type("fastq.bz2", "fastqsanger.bz2"):
53 #set read1 = $name_1 + '.fastq.bz2'
54 #set compressed = "BZ2"
55 #else if $library.input_1.forward.is_of_type('fasta'):
56 #set reads_are_fastq = False
57 #set read1 = $name_1 + '.fasta'
58 #else:
59 #set read1 = $name_1 + '.fastq'
60 #end if
61 ln -s '${library.input_1.forward}' ${read1} &&
62
63 #if $library.input_1.reverse.is_of_type("fastq.gz", "fastqsanger.gz"):
64 #set read2 = $name_2 + '.fastq.gz'
65 #set compressed = "GZ"
66 #else if $library.input_1.reverse.is_of_type("fastq.bz2", "fastqsanger.bz2"):
67 #set read2 = $name_2 + '.fastq.bz2'
68 #set compressed = "BZ2"
69 #else if $library.input_1.reverse.is_of_type("fasta"):
70 #set read2 = $name_2 + '.fasta'
71 #else:
72 #set read2 = $name_2 + '.fastq'
73 #end if
74 ln -s '${library.input_1.reverse}' ${read2} &&
75
76 #else if str($library.type) == 'paired_interleaved':
77 #set name_1 = re.sub('[^\w\-\s]', '_', str($library.input_1.element_identifier))
78 #if $library.input_1.is_of_type("fastq.gz", "fastqsanger.gz"):
79 #set read1 = $name_1 + '.fastq.gz'
80 #set compressed = "GZ"
81 #else if $library.input_1.is_of_type("fastq.bz2", "fastqsanger.bz2"):
82 #set read1 = $name_1 + '.fastq.bz2'
83 #set compressed = "BZ2"
84 #else if $library.input_1.is_of_type("fasta"):
85 #set reads_are_fastq = False
86 #set read1 = $name_1 + '.fasta'
87 #else:
88 #set read1 = $name_1 + '.fastq'
89 #end if
90 ln -s '${library.input_1}' ${read1} &&
91 #else:
92 #set name_1 = re.sub('[^\w\-\s]', '_', str($library.input_1.element_identifier))
93 #if $library.input_1.is_of_type("fastq.gz", "fastqsanger.gz"):
94 #set read1 = $name_1.fastq.gz
95 #set compressed = "GZ"
96 #else if $library.input_1.is_of_type("fastq.bz2", "fastqsanger.bz2"):
97 #set read1 = $name_1.fastq.bz2
98 #set compressed = "BZ2"
99 #else if $library.input_1.is_of_type("fasta"):
100 #set reads_are_fastq = False
101 #set read1 = $name_1 + '.fasta'
102 #else:
103 #set read1 = $name_1 + '.fastq'
104 #end if
105 ln -s '${library.input_1}' ${read1} &&
106 #end if
107
108 metamlst-index.py
109 -i bowtie_MmetaMLST
110 -d '$metamlstdb.fields.path' &&
111
112 bowtie2
113 --very-sensitive-local
114 -a
115 --no-unal
116
117 ## number of threads
118 -p \${GALAXY_SLOTS:-4}
119
120 ## index file path
121 -x bowtie_MmetaMLST
122
123 ## Input reads
124 #if str( $library.type ) == "single":
125 -U '${read1}'
126 #elif str( $library.type ) == "paired_interleaved":
127 --interleaved '${read1}'
128 #else:
129 -1 '${read1}'
130 -2 '${read2}'
131 #end if
132 | samtools view -bS -F 4 - > ${read1}.bam &&
133 metamlst.py
134 #if $filter_species.filter=='yes'
135 #set species_list = ",".join([$species for $species in $filter_species.species])
136 --filter $species_list
137 #end if
138 --penalty $penalty
139 --minscore $minscore
140 --max_xM $max_xm
141 --min_read_len $min_read_len
142 --min_accuracy $min_accuracy
143 --nloci $nloci
144 $log
145 $write_sequences
146 ${read1}.bam
147 -o ./out
148 -d '$metamlstdb.fields.path' &&
149 metamlst-merge.py ./out -d '$metamlstdb.fields.path' &&
150 #if $log
151 cat ./out/*.out > log.txt &&
152 #end if
153 #if $write_sequences
154 cat ./out/*.nfo > sequences.txt
155 #end if
156 ]]> </command>
157
158 <inputs>
159 <conditional name="library">
160 <param name="type" type="select" label="Is this single or paired library">
161 <option value="single">Single-end</option>
162 <option value="paired">Paired-end</option>
163 <option value="paired_collection">Paired-end Dataset Collection</option>
164 <option value="paired_interleaved">Paired-end data from single interleaved dataset</option>
165 </param>
166
167 <when value="single">
168 <param name="input_1" format="fastqsanger,fastqsanger.gz,fastqsanger.bz2" type="data" label="FASTA/Q file" help="Must be of datatype &quot;fastqsanger&quot; or &quot;fasta&quot;" />
169 </when>
170 <when value="paired">
171 <param name="input_1" format="fastqsanger,fastqsanger.gz,fastqsanger.bz2" type="data" label="FASTA/Q file #1" help="Must be of datatype &quot;fastqsanger&quot;or &quot;fasta&quot;" />
172 <param name="input_2" format="fastqsanger,fastqsanger.gz,fastqsanger.bz2" type="data" label="FASTA/Q file #2" help="Must be of datatype &quot;fastqsanger&quot;or &quot;fasta&quot;" />
173 </when>
174 <when value="paired_collection">
175 <param name="input_1" format="fastqsanger,fastqsanger.gz,fastqsanger.bz2" type="data_collection" collection_type="paired" label="FASTQ Paired Dataset" help="Must be of datatype &quot;fastqsanger&quot; or &quot;fasta&quot;" />
176 </when>
177 <when value="paired_interleaved">
178 <param name="input_1" format="fastqsanger,fastqsanger.gz,fastqsanger.bz2" type="data" label="Interleaved FASTQ file" help="Must be of datatype &quot;fastqsanger&quot; or &quot;fasta&quot;. --interleaved"/>
179 </when>
180 </conditional>
181 <param name="metamlstdb" label="Select a database" type="select">
182 <options from_data_table="metamlstdb">
183 <validator message="No database is available" type="no_options" />
184 </options>
185 </param>
186 <conditional name="filter_species">
187 <param name="filter" type="select" label="Filtering species">
188 <option value="yes">Yes</option>
189 <option value="no" selected="true">No</option>
190 </param>
191 <when value="yes">
192 <param name="species" type="select" multiple="true" label="Filter species">
193 <option value="achromobacter">Achromobacter spp.</option>
194 <option value="abaumannii1">Acinetobacter baumannii#1</option>
195 <option value="abaumannii2">Acinetobacter baumannii#2</option>
196 <option value="aeromonas">Aeromonas spp.</option>
197 <option value="aactinomycetemcomitans">Aggregatibacter actinomycetemcomitans</option>
198 <option value="aphagocytophilum">Anaplasma phagocytophilum</option>
199 <option value="arcobacter">Arcobacter spp.</option>
200 <option value="afumigatus">Aspergillus fumigatus</option>
201 <option value="bcereus">Bacillus cereus</option>
202 <option value="blicheniformis">Bacillus licheniformis</option>
203 <option value="bsubtilis">Bacillus subtilis</option>
204 <option value="bbacilliformis">Bartonella bacilliformis</option>
205 <option value="bhenselae">Bartonella henselae</option>
206 <option value="bwashoensis">Bartonella washoensis</option>
207 <option value="bordetella">Bordetella spp.</option>
208 <option value="borrelia">Borrelia spp.</option>
209 <option value="bhampsonii">Brachyspira hampsonii</option>
210 <option value="bhyodysenteriae">Brachyspira hyodysenteriae</option>
211 <option value="bintermedia">Brachyspira intermedia</option>
212 <option value="bpilosicoli">Brachyspira pilosicoli</option>
213 <option value="brachyspira">Brachyspira spp.</option>
214 <option value="brucella">Brucella spp.</option>
215 <option value="bcepacia">Burkholderia cepacia complex</option>
216 <option value="bpseudomallei">Burkholderia pseudomallei</option>
217 <option value="cconcisus-curvus">Campylobacter concisus/curvus</option>
218 <option value="cfetus">Campylobacter fetus</option>
219 <option value="chelveticus">Campylobacter helveticus</option>
220 <option value="chyointestinalis">Campylobacter hyointestinalis</option>
221 <option value="cinsulaenigrae">Campylobacter insulaenigrae</option>
222 <option value="cjejuni">Campylobacter jejuni</option>
223 <option value="clanienae">Campylobacter lanienae</option>
224 <option value="clari">Campylobacter lari</option>
225 <option value="csputorum">Campylobacter sputorum</option>
226 <option value="cupsaliensis">Campylobacter upsaliensis</option>
227 <option value="calbicans">Candida albicans</option>
228 <option value="cglabrata">Candida glabrata</option>
229 <option value="ckrusei">Candida krusei</option>
230 <option value="ctropicalis">Candida tropicalis</option>
231 <option value="cliberibacter">Candidatus Liberibacter solanacearum</option>
232 <option value="cmaltaromaticum">Carnobacterium maltaromaticum</option>
233 <option value="chlamydiales">Chlamydiales spp.</option>
234 <option value="cfreundii">Citrobacter freundii</option>
235 <option value="csinensis">Clonorchis sinensis</option>
236 <option value="cdifficile">Clostridioides difficile</option>
237 <option value="cbotulinum">Clostridium botulinum</option>
238 <option value="cperfringens">Clostridium perfringens</option>
239 <option value="csepticum">Clostridium septicum</option>
240 <option value="cdiphtheriae">Corynebacterium diphtheriae</option>
241 <option value="cronobacter">Cronobacter spp.</option>
242 <option value="dnodosus">Dichelobacter nodosus</option>
243 <option value="edwardsiella">Edwardsiella spp.</option>
244 <option value="ecloacae">Enterobacter cloacae</option>
245 <option value="efaecalis">Enterococcus faecalis</option>
246 <option value="efaecium">Enterococcus faecium</option>
247 <option value="ecoli1">Escherichia coli#1</option>
248 <option value="ecoli2">Escherichia coli#2</option>
249 <option value="fpsychrophilum">Flavobacterium psychrophilum</option>
250 <option value="ganatis">Gallibacterium anatis</option>
251 <option value="geotrichum">Geotrichum spp.</option>
252 <option value="gparasuis">Glaesserella parasuis</option>
253 <option value="hinfluenzae">Haemophilus influenzae</option>
254 <option value="hcinaedi">Helicobacter cinaedi</option>
255 <option value="hpylori">Helicobacter pylori</option>
256 <option value="hsuis">Helicobacter suis</option>
257 <option value="kkingae">Kingella kingae</option>
258 <option value="kaerogenes">Klebsiella aerogenes</option>
259 <option value="koxytoca">Klebsiella oxytoca</option>
260 <option value="kpneumoniae">Klebsiella pneumoniae</option>
261 <option value="kseptempunctata">Kudoa septempunctata</option>
262 <option value="lsalivarius">Lactobacillus salivarius</option>
263 <option value="leptospira">Leptospira spp.</option>
264 <option value="leptospira2">Leptospira spp.#2</option>
265 <option value="leptospira3">Leptospira spp.#3</option>
266 <option value="lmonocytogenes">Listeria monocytogenes</option>
267 <option value="mcanis">Macrococcus canis</option>
268 <option value="mcaseolyticus">Macrococcus caseolyticus</option>
269 <option value="mhaemolytica">Mannheimia haemolytica</option>
270 <option value="mplutonius">Melissococcus plutonius</option>
271 <option value="mcatarrhalis">Moraxella catarrhalis</option>
272 <option value="mycobacteria">Mycobacteria spp.</option>
273 <option value="mabscessus">Mycobacterium abscessus</option>
274 <option value="mmassiliense">Mycobacterium massiliense</option>
275 <option value="magalactiae">Mycoplasma agalactiae</option>
276 <option value="mbovis">Mycoplasma bovis (legacy)</option>
277 <option value="mflocculare">Mycoplasma flocculare</option>
278 <option value="mgallisepticum1">Mycoplasma gallisepticum#1</option>
279 <option value="mgallisepticum2">Mycoplasma gallisepticum#2</option>
280 <option value="mhominis">Mycoplasma hominis</option>
281 <option value="mhyopneumoniae">Mycoplasma hyopneumoniae</option>
282 <option value="mhyorhinis">Mycoplasma hyorhinis</option>
283 <option value="miowae">Mycoplasma iowae</option>
284 <option value="mpneumoniae">Mycoplasma pneumoniae</option>
285 <option value="msynoviae">Mycoplasma synoviae</option>
286 <option value="neisseria">Neisseria spp.</option>
287 <option value="otsutsugamushi">Orientia tsutsugamushi</option>
288 <option value="orhinotracheale">Ornithobacterium rhinotracheale</option>
289 <option value="plarvae">Paenibacillus larvae</option>
290 <option value="pmultocida1">Pasteurella multocida#1</option>
291 <option value="pmultocida2">Pasteurella multocida#2</option>
292 <option value="ppentosaceus">Pediococcus pentosaceus</option>
293 <option value="pdamselae">Photobacterium damselae</option>
294 <option value="psalmonis">Piscirickettsia salmonis</option>
295 <option value="pgingivalis">Porphyromonas gingivalis</option>
296 <option value="pacnes">Propionibacterium acnes</option>
297 <option value="paeruginosa">Pseudomonas aeruginosa</option>
298 <option value="pfluorescens">Pseudomonas fluorescens</option>
299 <option value="pputida">Pseudomonas putida</option>
300 <option value="rhodococcus">Rhodococcus spp.</option>
301 <option value="ranatipestifer">Riemerella anatipestifer</option>
302 <option value="senterica">Salmonella enterica</option>
303 <option value="sparasitica">Saprolegnia parasitica</option>
304 <option value="shewanella">Shewanella spp.</option>
305 <option value="sinorhizobium">Sinorhizobium spp.</option>
306 <option value="saureus">Staphylococcus aureus</option>
307 <option value="schromogenes">Staphylococcus chromogenes</option>
308 <option value="sepidermidis">Staphylococcus epidermidis</option>
309 <option value="shaemolyticus">Staphylococcus haemolyticus</option>
310 <option value="shominis">Staphylococcus hominis</option>
311 <option value="slugdunensis">Staphylococcus lugdunensis</option>
312 <option value="spseudintermedius">Staphylococcus pseudintermedius</option>
313 <option value="smaltophilia">Stenotrophomonas maltophilia</option>
314 <option value="sagalactiae">Streptococcus agalactiae</option>
315 <option value="sbovis-equinus">Streptococcus bovis/equinus complex (SBSEC)</option>
316 <option value="scanis">Streptococcus canis</option>
317 <option value="sdysgalactiae">Streptococcus dysgalactiae equisimilis</option>
318 <option value="sgallolyticus">Streptococcus gallolyticus</option>
319 <option value="soralis">Streptococcus oralis</option>
320 <option value="spneumoniae">Streptococcus pneumoniae</option>
321 <option value="spyogenes">Streptococcus pyogenes</option>
322 <option value="ssuis">Streptococcus suis</option>
323 <option value="sthermophilus">Streptococcus thermophilus</option>
324 <option value="sthermophilus2">Streptococcus thermophilus#2</option>
325 <option value="suberis">Streptococcus uberis</option>
326 <option value="szooepidemicus">Streptococcus zooepidemicus</option>
327 <option value="streptomyces">Streptomyces spp</option>
328 <option value="taylorella">Taylorella spp.</option>
329 <option value="tenacibaculum">Tenacibaculum spp.</option>
330 <option value="tpallidum">Treponema pallidum</option>
331 <option value="tvaginalis">Trichomonas vaginalis</option>
332 <option value="ureaplasma">Ureaplasma spp.</option>
333 <option value="vcholerae">Vibrio cholerae</option>
334 <option value="vcholerae2">Vibrio cholerae#2</option>
335 <option value="vparahaemolyticus">Vibrio parahaemolyticus</option>
336 <option value="vibrio">Vibrio spp.</option>
337 <option value="vtapetis">Vibrio tapetis</option>
338 <option value="vvulnificus">Vibrio vulnificus</option>
339 <option value="wolbachia">Wolbachia </option>
340 <option value="xfastidiosa">Xylella fastidiosa</option>
341 <option value="ypseudotuberculosis">Yersinia pseudotuberculosis</option>
342 <option value="yruckeri">Yersinia ruckeri</option>
343 </param>
344 </when>
345 </conditional>
346 <param argument="--penalty" type="integer" min="0" value="100" label="MetaMLST penaty for under-represented alleles" />
347 <param argument="--minscore" type="integer" min="0" value="80" label="Minimum alignment score for each alignment to be considered valid" />
348 <param argument="--max_xm" type="integer" min="0" value="5" label="Maximum SNPs rate for each alignment to be considered valid" />
349 <param argument="--min_read_len" type="integer" min="0" value="50" label="Minimum BowTie2 alignment length" />
350 <param argument="--min_accuracy" type="float" min="0" max="1" value="0.9" label="Minimum threshold on Confidence score to pass the reconstruction step" />
351 <param argument="--nloci" type="integer" min="0" value="100" label="Do not discard samples where at least NLOCI are detected" />
352 <param argument="--log" type="boolean" truevalue="--log" falsevalue="" checked="true" label="Generate log file" />
353 <param name="write_sequences" type="boolean" truevalue="-a" falsevalue="" checked="false" label="Write known sequences" />
354 </inputs>
355
356 <outputs>
357 <collection name="report" type="list" label="${tool.name} on ${on_string} Report">
358 <discover_datasets pattern="(?P&lt;designation&gt;[a-zA-Z0-9\-\_]+)_report\.txt$" format="tabular" directory="./out/merged" visible="false"/>
359 </collection>
360 <collection name="st" type="list" label="${tool.name} on ${on_string} ST">
361 <discover_datasets pattern="(?P&lt;designation&gt;[a-zA-Z0-9\-\_]+)_ST\.txt$" format="tabular" directory="./out/merged" visible="false"/>
362 </collection>
363 <data name="log_file" format="txt" from_work_dir="log.txt" label="${tool.name} on ${on_string} Log">
364 <filter>log == True</filter>
365 </data>
366 <data name="sequence" format="txt" from_work_dir="sequences.txt" label="${tool.name} on ${on_string} Sequences">
367 <filter>write_sequences == True</filter>
368 </data>
369 </outputs>
370 <!-- <tests>
371 <test>
372 </test>
373 </tests> -->
374 <help><![CDATA[
375 ]]> </help>
376 <citations>
377 <citation type="doi">10.1093/nar/gkw837</citation>
378 </citations>
379 </tool>