comparison bank_inhouse.xml @ 0:be582bcd6585 draft

Master branch Updating - - Fxx
author fgiacomoni
date Thu, 04 Oct 2018 10:37:14 -0400
parents
children 52798007c6b2
comparison
equal deleted inserted replaced
-1:000000000000 0:be582bcd6585
1 <tool id="bank_inhouse" name="bank_inhouse" version="1.1.3">
2 <description>
3 search by accurate mass (and by Retention time) on a local bank
4 </description>
5
6 <requirements>
7 <requirement type="package" version="2.90">perl-json</requirement>
8 <requirement type="package" version="1.97">perl-text-csv</requirement>
9 <requirement type="package" version="6.15">perl-lwp-simple</requirement>
10 <requirement type="package" version="1.74">perl-uri</requirement>
11 <requirement type="package" version="1.19">perl-soap-lite</requirement>
12 <requirement type="package" version="2.97">perl-html-template</requirement>
13 <requirement type="package" version="0.428">perl-list-moreutils</requirement>
14 <requirement type="package" version="6.15">perl-libwww-perl</requirement>
15 </requirements>
16 <stdio>
17 <exit_code range="1" level="fatal" />
18 </stdio>
19
20 <command><![CDATA[
21 perl $__tool_directory__/bank_inhouse.pl
22
23 #if str($input_type.choice) == "YES":
24 -input "${input_type.variableMetadata_in}"
25 #if str($input_type.header.header_choice) == "YES":
26 -nbheader "${input_type.header.nbheader}"
27 #end if
28
29 -colmass "${input_type.colmass}"
30 #if str($input_type.use_file_rt.rt_file_choice) == "YES":
31 -colrt "${input_type.use_file_rt.colrt}"
32 -rt_delta "${input_type.use_file_rt.rt_file_delta}"
33 #end if
34 #else:
35 #if str($input_type.use_rt.rt_choice) == "YES":
36 -rt "${input_type.use_rt.rt}"
37 -rt_delta "${input_type.use_rt.rt_delta}"
38 #end if
39 -masse "${input_type.masse}"
40 #end if
41
42 -mz_delta "${mz_delta_type.mz_delta}"
43 -mass_delta "${mz_delta_type.mass_delta}"
44
45 #if str($bank_type.perso_bank) == "YES":
46 -bank_in "${bank_type.bank_in}" -bank_name "${bank_type.bank_in.name}"
47 -mzdb "${bank_type.mzdb}"
48 #if str($bank_type.bank_rt.bank_rt_choice) == "YES":
49 -rtdb "${bank_type.bank_rt.rtdb}"
50 #end if
51 #end if
52
53 #if str($input_type.choice) == "YES":
54 -outputTab "$variableMetadata_out"
55 -outputXls "$bankInhouseResXls_filein"
56 #if str($outfiles) == "YES":
57 -outputFull "$variableMetadata_full_out"
58 #end if
59 #else:
60 -outputXls "$bankInhouseResXls_manualin"
61 #end if
62
63 #if str($outfiles) == "YES":
64 -outputJson "$Json"
65 #end if
66 ]]></command>
67
68 <inputs>
69 <conditional name="input_type">
70 <param name="choice" type="select" display="radio" label="* Would you use a file?" help="if 'NO' is selected then one or more mass(es) must be entered manually">
71 <option value="NO">NO</option>
72 <option value="YES" selected="true">YES</option>
73 </param>
74 <when value="YES">
75 <param name="variableMetadata_in" type="data" label="FILE OF MASSES (format: tabular)" help="Generally variable metadata file" format="tabular" />
76
77 <conditional name="header">
78 <param name="header_choice" type="boolean" checked="true" truevalue="YES" falsevalue="NO" label="Do you have a header?" help="if 'YES' is selected then enter your number of header lines" />
79 <when value="YES">
80 <param name="nbheader" type="integer" label="Number of header lines" value="1" min="1" max="10" help="number of lines not containing masses"/>
81 </when>
82 <when value="NO"/>
83 </conditional>
84
85 <conditional name="use_file_rt">
86 <param name="rt_file_choice" type="boolean" checked="true" truevalue="YES" falsevalue="NO" label="Would you use retention time (RT)?" help="Do you have retention times in your bank? In your analyzed file? Would you use it?" />
87 <when value="YES">
88 <param name="colrt" label="Column of retention time (RT)" type="data_column" data_ref="variableMetadata_in" accept_default="true" />
89 <param name="rt_file_delta" label="Delta of retention time (RT) (in minutes)" type="float" value="0.1" min="0" max="60" help="Default value is 0.1min"/>
90 </when>
91 <when value="NO"/>
92 </conditional>
93
94 <param name="colmass" label="Column of masses (MZ)" type="data_column" data_ref="variableMetadata_in" accept_default="true" />
95 </when>
96 <when value="NO">
97 <conditional name="use_rt">
98 <param name="rt_choice" type="boolean" checked="true" truevalue="YES" falsevalue="NO" label="Would you use retention time (RT)?" help="Do you have retention times in your bank? Would you use it?" />
99 <when value="YES">
100 <param name="rt" label="retention time (RT) to submit" type="text" size="10" help="For a rt list, writes : rt1 rt2 rt3. Your values ​​must be separated by spaces. You should use dot (.) like decimal separator"/>
101 <param name="rt_delta" label="Delta of retention time (RT) (in minutes)" type="float" value="0.1" min="0" max="60" help="Default value is 0.1min"/>
102 </when>
103 <when value="NO"/>
104 </conditional>
105
106 <param name="masse" type="text" label="Mass (MZ) to submit" size="20" help="For a masses list, writes : m1 m2 m3. Your values ​​must be separated by spaces. You should use dot (.) like decimal separator"/>
107 </when>
108 </conditional>
109
110 <conditional name="mz_delta_type">
111 <param name="mz_delta" label="Delta type" type="select" display="radio" help="">
112 <option value="Da">Da</option>
113 <option value="ppm">ppm</option>
114 </param>
115 <when value="Da">
116 <param name="mass_delta" label="Delta of mass (MZ) (in Dalton)" type="float" value="0.005" min="0" max="3000" help="Default value is 0.005 Da"/>
117 </when>
118 <when value="ppm">
119 <param name="mass_delta" label="Delta of mass (MZ) (in ppm)" type="float" value="5" min="0" max="300000" help="Default value is 5 ppm"/>
120 </when>
121 </conditional>
122
123 <conditional name="bank_type">
124 <param name="perso_bank" type="boolean" checked="true" truevalue="YES" falsevalue="NO" label="* Use personal data bank?" help="if 'NO' is selected an internal file will be used! It doesn't contain a retention time (RT)" />
125 <when value="YES">
126 <param name="bank_in" type="data" label="BANK FILE" help="" format="tabular" />
127 <param name="mzdb" label="Column of masses (MZ) in Bank file" type="data_column" data_ref="bank_in" accept_default="true" />
128 <conditional name="bank_rt">
129 <param name="bank_rt_choice" type="boolean" checked="true" truevalue="YES" falsevalue="NO" label="Have you used the retention time (RT) for your input data?" help="Do you have retention times in your bank? In your analyzed data? Would you use it?" />
130 <when value="YES">
131 <param name="rtdb" label="Column of retention time (RT) in Bank file" type="data_column" data_ref="bank_in" accept_default="true" />
132 </when>
133 <when value="NO"/>
134 </conditional>
135 </when>
136 <when value="NO"/>
137 </conditional>
138 <param name="outfiles" type="select" label="* Would you more output?" display="radio" help="if 'YES' is selected then 2 more files will be generate (JSON + variableMetadata and bank full column)">
139 <option value="YES">YES</option>
140 <option value="NO" selected="true">NO</option>
141 </param>
142 </inputs>
143
144 <outputs>
145 <data name="variableMetadata_out" format="tabular" label="${tool.name}_${input_type.variableMetadata_in.name}_TSV" >
146 <filter>(input_type['choice'] == 'YES')</filter>
147 </data>
148 <data name="bankInhouseResXls_filein" format="tabular" label="${tool.name}_${input_type.variableMetadata_in.name}_XLS" >
149 <filter>(input_type['choice'] == 'YES')</filter>
150 </data>
151 <data name="variableMetadata_full_out" format="tabular" label="${tool.name}_${input_type.variableMetadata_in.name}_full_TSV" >
152 <filter>(input_type['choice'] == 'YES')</filter>
153 <filter>(outfiles == 'YES')</filter>
154 </data>
155 <data name="bankInhouseResXls_manualin" format="tabular" label="${tool.name}_manual_XLS" >
156 <filter>(input_type['choice'] == 'NO')</filter>
157 </data>
158 <data name="Json" format="vjson" label="${tool.name}_Json" >
159 <filter>(outfiles == 'YES')</filter>
160 </data>
161 <!--<data name="View" format="html" label="${tool.name}_View" ></data>-->
162 </outputs>
163
164 <tests>
165 <test>
166 <param name="choice" value="NO"/>
167 <param name="rt_choice" value="NO"/>
168 <param name="masse" value="422.0849114 18.0105647 535.3181236 209.987659 98.952389"/>
169 <param name="mz_delta" value="Da"/>
170 <param name="mass_delta" value="0.005"/>
171 <param name="perso_bank" value="NO"/>
172 <param name="outfiles" value="NO"/>
173 <output name="bankInhouseResXls_manualin" file="out_test1.tabular"/>
174 </test>
175 <test>
176 <param name="choice" value="YES"/>
177 <param name="variableMetadata_in" value="in_test2.tabular"/>
178 <param name="header_choice" value="YES"/>
179 <param name="nbheader" value="1"/>
180 <param name="rt_file_choice" value="NO"/>
181 <param name="colmass" value="2"/>
182 <param name="mz_delta" value="Da"/>
183 <param name="mass_delta" value="0.005"/>
184 <param name="perso_bank" value="NO"/>
185 <param name="outfiles" value="NO"/>
186
187 <output name="variableMetadata_out" file="out_test2a.tabular"/>
188 <output name="bankInhouseResXls_filein" file="out_test2b.tabular"/>
189 </test>
190 <!--
191 <test>
192 <param name="choice" value="YES"/>
193 <param name="variableMetadata_in" value="in_test3.tabular"/>
194 <param name="header_choice" value="YES"/>
195 <param name="nbheader" value="1"/>
196 <param name="rt_file_choice" value="NO"/>
197 <param name="colmass" value="2"/>
198 <param name="mz_delta" value="Da"/>
199 <param name="mass_delta" value="0.005"/>
200 <param name="perso_bank" value="NO"/>
201 <param name="outfiles" value="NO"/>
202
203 <output name="variableMetadata_out" file="out_test3a.tabular"/>
204 <output name="bankInhouseResXls_filein" file="out_test3b.tabular"/>
205 </test>
206 <test>
207 <param name="choice" value="YES"/>
208 <param name="variableMetadata_in" value="in_test4.tabular"/>
209 <param name="header_choice" value="YES"/>
210 <param name="nbheader" value="1"/>
211 <param name="rt_file_choice" value="YES"/>
212 <param name="colrt" value="10"/>
213 <param name="rt_file_delta" value="0.2"/>
214 <param name="colmass" value="8"/>
215 <param name="mz_delta" value="Da"/>
216 <param name="mass_delta" value="0"/>
217 <param name="perso_bank" value="YES"/>
218 <param name="bank_in" value="in_test4.tabular"/>
219 <param name="mzdb" value="8"/>
220 <param name="bank_rt_choice" value="YES"/>
221 <param name="rtdb" value="10"/>
222 <param name="outfiles" value="YES"/>
223
224 <output name="variableMetadata_out" file="out_test4a.tabular"/>
225 <output name="bankInhouseResXls_filein" file="out_test4b.tabular"/>
226 <output name="variableMetadata_full_out" file="out_test4c.tabular"/>
227 <output name="Json" file="out_test4d.vjson"/>
228 </test>-->
229 </tests>
230
231 <help><![CDATA[
232
233 .. class:: infomark
234
235 **Authors**
236 | Marion Landi - FLAME ; PFEM ; INRA ; MetaboHUB (for original version and development of this Perl script and for xml interface and Perl wrapper)
237
238 ---------------------------------------------------
239
240
241 ==============
242 bank_inhouse
243 ==============
244
245 -----------
246 Description
247 -----------
248
249 | Search informations on a local bank with one or more mass(es), with or without retention time, in a file or entered manually
250
251
252 Keywords
253 ========
254
255 Masses + rt to inhouse info
256
257
258 -----------------
259 Workflow position
260 -----------------
261
262
263 .. image:: bank_inhouse.png
264 :width: 800
265
266
267 -----------
268 Input files
269 -----------
270
271
272 +-----------------------------+-----------+
273 | Parameter : num + label | Format |
274 +=============================+===========+
275 | 1 : File of masses | tabular |
276 +-----------------------------+-----------+
277 | 2 : personal data bank file | tabular |
278 +-----------------------------+-----------+
279
280 File of masses (Generally variable metadata file) must have at least the 2 following column :
281 | Id : column to identify masses in the tsv input file
282 | Masses : column with all the masses in the tsv input file
283 | RT : (optional) column with all the retention time in the tsv input file
284 |
285
286 personal data bank file must contain certain columns :
287 | Masses (Mandatory) and RT (optional)
288 |
289
290 ----------
291 Parameters
292 ----------
293
294 Would you use a file
295 | Choose whether the masses are in a file or entered manually
296 | YES (default) : parameters **File of masses ; Do you have a header ; Column of Id ; Column of masses** are visible
297 | NO : parameter **Mass to submit** is visible
298 |
299
300
301 If 'use file'='YES'
302
303 File of masses
304 | see "Input files" section above
305 | Tabular file format, Generally variable metadata file
306 |
307
308 Do you have a header
309 | YES (default) : parameter **Number of header lines** is visible
310 | NO : all lines are considered to contain masses
311 |
312
313 If 'have a header'='YES'
314
315 Number of header lines
316 | Number of lines not containing masses values, these lines will be ignored
317 |
318
319 In all header cases :
320
321 Column of Id
322 | Specify the column number for the id in the tsv input file
323 |
324
325 Would you use retention time (RT)
326 | YES (default) : parameter **Column of retention time (RT)** and **Delta of retention time (RT) (in minutes)** are visible
327 | NO : Search will be made solely on the basis of the masses
328 |
329
330 If 'Would you use retention time (RT)'='YES'
331
332 Column of retention time (RT)
333 | Specify the column number for the retention time (RT) in the tsv input file
334 |
335
336 Delta of retention time (RT) (in minutes)
337 | Specify a delta to apply on retention time - This value is a float.
338 |
339
340 In all RT cases :
341
342 Column of masses
343 | Specify the column number for the mass in the tsv input file
344 |
345
346
347 If 'use file'='NO'
348
349 Would you use retention time (RT)
350 | YES (default) : parameter **retention time (RT) to submit** and **Delta of retention time (RT) (in minutes)** are visible
351 | NO : Search will be made solely on the basis of the masses
352 |
353
354 If 'Would you use retention time (RT)'='YES'
355
356 retention time (RT) to submit
357 | Specify a list of retention time to request
358 | one or more retention time entered manually
359 | For a RT list, writes : rt1 rt2 rt3
360 | You must separate yours values with space
361 | dot (.) is for float number
362 |
363 Delta of retention time (RT) (in minutes)
364 | Specify a delta to apply on retention time - This value is a float.
365 |
366
367 In all RT cases :
368
369 Mass to submit
370 | Specify a list of mass to request
371 | one or more mass(es) entered manually
372 | For a masses list, writes : m1 m2 m3
373 | You must separate yours values with space
374 | dot (.) is for float number
375 |
376
377 In all cases :
378
379 Delta type
380 | Specify a delta type : "in Dalton" or "in ppm"
381 |
382
383 Delta of mass ("in Dalton" or "in ppm" according to choice)
384 | Specify a delta to apply on mass - This value is a float.
385 |
386
387 Use personal data bank
388 | YES : parameter **Bank file**, **Column of masses (MZ) in Bank file** and **Column of retention time (RT) in Bank file** (optional) are visible, the search will be made only on the information of the file
389 | NO : a internal bank will be used
390 |
391
392 If 'Use personal data bank'='YES'
393
394 Bank file
395 | see "Input files" section above
396 | Tabular file format, Generally variable metadata file
397 |
398
399 Column of masses
400 | Specify the column number for the mass in the bank input file
401 |
402
403 Have you used the retention time (RT) for your input data
404 | Answering same as for "Would you use retention time (RT)"
405 | YES (default) : parameter **Column of retention time (RT) in Bank file** is visible
406 | NO : Search will be made solely on the basis of the masses
407 |
408
409 Column of retention time (RT) in Bank file
410 | Specify the column number for the rt in the bank input file
411 |
412
413
414 ------------
415 Output files
416 ------------
417
418 Two types of files (if you manually enter the masses both files are mingled):
419 | bank_inhouse_(input.name)_TSV.tabular : for linking with others modules.
420 |
421 | bank_inhouse_(input.name)_XLS.tabular : an excel-like output will be available.
422 |
423
424
425 ---------------------------------------------------
426
427
428 ---------------
429 Working example
430 ---------------
431
432
433 .. class:: warningmark
434
435 Refer to the corresponding W4M HowTo section: http://workflow4metabolomics.org/howto
436 | Format Data For Postprocessing
437 | Perform LCMS Annotations
438
439 .. class:: warningmark
440
441 And their "W4M courses 2016":
442 | Using Galaxy4Metabolomics - W4M table format for Galaxy
443 | Annotation Banks - Annotation
444
445 ]]></help>
446 </tool>