annotate metams_lcms_annotate.xml @ 2:44bfd7e34b39

added comment
author pieter.lukasse@wur.nl
date Thu, 19 Mar 2015 10:39:27 +0100
parents dffc38727496
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
1 <tool id="metams_lcms_annotate" name="METAMS-LC/MS Annotate" version="0.0.4">
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
2 <description> Runs metaMS process for LC/MS feature annotation</description>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
3 <requirements>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
4 <requirement type="package" version="3.1.1">R_bioc_metams</requirement>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
5 </requirements>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
6 <command interpreter="Rscript">
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
7 metaMS_cmd_annotate.r
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
8 $constructed_db
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
9 $xsetData
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
10 $customMetaMSsettings
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
11 $outputFile
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
12 #if $mzTol.mzTolType == "fixed"
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
13 0
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
14 #else
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
15 "$mzTol.mass_error_function"
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
16 #end if
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
17 $htmlReportFile
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
18 $htmlReportFile.files_path
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
19 $outputLog
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
20 </command>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
21 <inputs>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
22 <param name="constructed_db" type="select" label="Constructed DB" help="Reference annotation database generated from matching measurements of a mixture of chemical standards
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
23 against a manually validated reference table which contains the key analytical information for each standard."
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
24 dynamic_options='get_directory_files("tool-data/shared/PRIMS-metabolomics/metaMS")'/>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
25
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
26 <param name="xsetData" type="data" format="rdata" label="xcmsSet data file (xset RDATA)" help="E.g. output data file resulting from METAMS 'feature picking, aligning and grouping' run"/>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
27
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
28 <param name="protocolName" type="text" size="30" label="protocolName" value="e.g. Synapt.QTOF.RP"
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
29 help="Choose a name to give for the specific settings in the parameters below"/>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
30
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
31 <param name="rtdiff" type="float" size="10" value="1.5" label="rtdiff" help="(Annotation) Allowed rt difference (in minutes)"/>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
32
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
33 <conditional name="mzTol">
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
34 <param name="mzTolType" type="select" size="30" label="(Annotation) m/z tolerance type">
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
35 <option value="fixed" selected="true">Fixed tolerance</option>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
36 <option value="adaptive" >Adaptive tolerance</option>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
37 </param>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
38 <when value="fixed">
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
39 <param name="mzdiff" type="float" size="10" value="0.005" label="mzdiff" help="(Annotation) Fixed mass tolerance" />
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
40 </when>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
41 <when value="adaptive">
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
42 <param name="ppm" type="float" size="10" value="5.0" label="ppm" help="(Annotation) Tolerance in ppm" />
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
43 <param name="mass_error_function" type="text" area="true" size="3x70" label="(Annotation) Mass error function"/>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
44 </when>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
45 </conditional>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
46
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
47 <param name="rtval" type="float" size="10" value="0.1" label="(max)rtval" help="(Validation) Group items are clustered once more with hierarchical clustering ('complete' method)
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
48 based on their rt distances. Here one can specify the rt threshold for removing the items that have too diverging rt (the ones with rt difference
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
49 larger than rtval). " />
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
50 <param name="minfeat" type="integer" size="10" value="2" label="minfeat"
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
51 help="(Validation) Threshold for the minimum number of features a
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
52 cluster/group should have (after rtval filtering above). Other clusters/groups are filtered out." />
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
53
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
54 </inputs>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
55 <configfiles>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
56
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
57 <configfile name="customMetaMSsettings">## start comment
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
58 ## metaMS process settings
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
59 customMetaMSsettings &lt;- metaMSsettings(protocolName = "${protocolName}",
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
60 chrom = "LC")
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
61 metaSetting(customMetaMSsettings, "match2DB") &lt;- list(
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
62 rtdiff = ${rtdiff},
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
63 rtval = ${rtval},
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
64 #if $mzTol.mzTolType == "fixed"
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
65 mzdiff = ${mzTol.mzdiff},
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
66 #else
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
67 ppm = ${mzTol.ppm},
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
68 #end if
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
69 minfeat = ${minfeat})</configfile>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
70
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
71 </configfiles>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
72
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
73 <outputs>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
74 <data name="outputFile" format="tabular" label="${tool.name} on ${on_string} - metaMS annotated file (TSV)"/>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
75 <data name="outputLog" format="txt" label="${tool.name} on ${on_string} - metaMS LOG" hidden="True"/>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
76 <data name="htmlReportFile" format="html" label="${tool.name} on ${on_string} - metaMS report (HTML)"/>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
77 </outputs>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
78 <tests>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
79 <test>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
80 </test>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
81 </tests>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
82 <code file="match_library.py" /> <!-- file containing get_directory_files function used above-->
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
83 <help>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
84
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
85 .. class:: infomark
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
86
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
87 Runs metaMS process for LC/MS feature annotation based on matching to an existing 'standards' DB.
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
88 The figure below shows the main parts of this metaMS process.
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
89
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
90 .. image:: $PATH_TO_IMAGES/metaMS_annotate.png
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
91
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
92
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
93 .. class:: infomark
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
94
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
95 The implemented annotation strategy can be broken down in the following steps:
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
96
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
97 1. *Feature wise Annotation:* Each feature detected by runLC is matched against the database. If
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
98 the mass error function is provided, the appropriate m/z tolerance is calculated, otherwise a fixed
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
99 tolerance is used (mzdiff). The retention time tolerance is fixed and should be selected on the
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
100 bases of the characteristics of each chromatographic method (rtdiff). Multiple annotations - i.e.
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
101 features which are associated to more than one compound - are possible. This outcome does not
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
102 indicate a problem per se, but is an inherent drawback of co-elution.
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
103
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
104 2. *Annotation Validation:* The annotated features are organized in 'pseudospectra' collecting all
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
105 the experimental features which are assigned to a specific compound. A specific annotation is
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
106 confirmed only if more than minfeat features which differ in retention time less than rtval are
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
107 present in a pseudospectrum. As a general rule rtval should be narrower than rtdiff. The
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
108 latter, indeed, accounts for shifts in retention time between the injection of the standards and the
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
109 metabolomics experiment under investigation. This time can be rather long, considering that the
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
110 standards are not commonly re-analyzed each time. On the other hand, rtval represents the shift
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
111 between the ions of the same compound within the same batch of injections and therefore it has
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
112 only to account for the smaller shifts occurring during peak picking and alignment.
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
113
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
114
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
115 </help>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
116 <citations>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
117 <citation type="doi">10.1016/j.jchromb.2014.02.051</citation> <!-- example
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
118 see also https://wiki.galaxyproject.org/Admin/Tools/ToolConfigSyntax#A.3Ccitations.3E_tag_set
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
119 -->
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
120 </citations>
dffc38727496 initial commit
pieter.lukasse@wur.nl
parents:
diff changeset
121 </tool>