comparison abims_xcms_fillPeaks.xml @ 31:8fd5b5afa24d draft

planemo upload for repository https://github.com/workflow4metabolomics/xcms commit e384d6dd5f410799ec211f73bca0b5d5d7bc651e
author lecorguille
date Thu, 01 Mar 2018 04:17:29 -0500
parents 6b5ed508f81f
children ea611367e1da
comparison
equal deleted inserted replaced
30:6b5ed508f81f 31:8fd5b5afa24d
1 <tool id="abims_xcms_fillPeaks" name="xcms.fillPeaks" version="2.1.1"> 1 <tool id="abims_xcms_fillPeaks" name="xcms fillChromPeaks (fillPeaks)" version="@WRAPPER_VERSION@.0">
2 2
3 <description>Integrate a sample's signal in regions where peak groups are not represented to create new peaks in missing areas</description> 3 <description>Integrate areas of missing peaks</description>
4 4
5 <macros> 5 <macros>
6 <import>macros.xml</import> 6 <import>macros.xml</import>
7 </macros> 7 </macros>
8 8
9 <expand macro="requirements"/> 9 <expand macro="requirements"/>
10 <expand macro="stdio"/> 10 <expand macro="stdio"/>
11 11
12 <command><![CDATA[ 12 <command><![CDATA[
13 @COMMAND_XCMS_SCRIPT@ 13 @COMMAND_XCMS_SCRIPT@/xcms_fillpeaks.r
14 xfunction fillPeaks 14
15 image '$image' 15 image '$image'
16 16
17 xsetRdataOutput '$xsetRData' 17 ## Advanced
18 18 expandMz $Adv.expandMz
19 method $method 19 expandRt $Adv.expandRt
20 ppm $Adv.ppm
20 21
21 @COMMAND_PEAKLIST@ 22 @COMMAND_PEAKLIST@
22 23
23 @COMMAND_FILE_LOAD@ 24 @COMMAND_FILE_LOAD@
24 25
26 27
27 ]]></command> 28 ]]></command>
28 29
29 <inputs> 30 <inputs>
30 <param name="image" type="data" format="rdata.xcms.group,rdata" label="xset RData file" help="output file from another xcms function (group)" /> 31 <param name="image" type="data" format="rdata.xcms.group,rdata" label="xset RData file" help="output file from another xcms function (group)" />
31 <param name="method" type="select" label="Filling method" help="[method] See the help section below"> 32
32 <option value="chrom" selected="true">chrom</option> 33 <section name="Adv" title="Advanced Options" expanded="False">
33 <option value="MSW" >MSW</option> 34 <param argument="expandMz" type="integer" value="0" label="Value by which the mz width of peaks should be expanded" help="Each peak is expanded in mz direction by ‘expandMz *’ their original mz width. A value of ‘0’ means no expansion, a value of ‘1’ grows each peak by 1 * the mz width of the peak resulting in peakswith twice their original size in mz direction (expansion by half mz width to both sides)." />
34 </param> 35 <param argument="expandRt" type="integer" value="0" label="Value by which the RT width of peaks should be expanded" help="Each peak is expanded in RT direction by ‘expandRt *’ their original RT width. A value of ‘0’ means no expansion, a value of ‘1’ grows each peak by 1 * the RT width of the peak resulting in peakswith twice their original size in RT direction (expansion by half RT width to both sides)."/>
36 <param argument="ppm" type="integer" value="0" label="Specifying a ppm by which the mz width of the peak region should be expanded" help="For peaks with an mz width smaller than ‘mean(c(mzmin, mzmax)) * ppm / 1e6’, the ‘mzmin’ will be replaced by ‘mean(c(mzmin, mzmax)) - (mean(c(mzmin, mzmax)) * ppm / 2 / 1e6)’ and ‘mzmax’ by ‘mean(c(mzmin, mzmax)) + (mean(c(mzmin, mzmax)) * ppm / 2 / 1e6)’. This is applied before eventually expanding the mz width using the ‘expandMz’ parameter." />
37 </section>
35 38
36 <expand macro="input_peaklist"/> 39 <expand macro="input_peaklist"/>
37 40
38 <expand macro="input_file_load"/> 41 <expand macro="input_file_load"/>
39 42
40 </inputs> 43 </inputs>
41 44
42 <outputs> 45 <outputs>
43 <data name="xsetRData" format="rdata.xcms.fillpeaks" label="${image.name[:-6]}.fillPeaks.RData" /> 46 <data name="xsetRData" format="rdata.xcms.fillpeaks" label="${image.name[:-6]}.fillPeaks.RData" from_work_dir="fillpeaks.RData" />
44 <expand macro="output_peaklist" function="fillpeaks" /> 47 <expand macro="output_peaklist" function="fillpeaks" />
45 <data name="log" format="txt" label="xset.log.txt" hidden="true" />
46 </outputs> 48 </outputs>
47 49
48 <tests> 50 <tests>
49 <!--<test> 51 <!--<test>
50 <param name="image" value="xset.group.retcor.group.RData"/> 52 <param name="image" value="xset.group.retcor.group.RData"/>
51 <param name="method" value="chrom"/> 53 <param name="method" value="chrom"/>
52 <param name="zip_file" value="sacuri_dir_root.zip" ftype="zip" /> 54 <param name="zip_file" value="sacuri_dir_root.zip" ftype="zip" />
53 <output name="log"> 55 <assert_stdout>
54 <assert_contents> 56 <has_text text="object with 4 samples" />
55 <has_text text="object with 4 samples" /> 57 <has_text text="Time range: 0.2-1140.1 seconds (0-19 minutes)" />
56 <has_text text="Time range: 0.2-1140.1 seconds (0-19 minutes)" /> 58 <has_text text="Mass range: 50.0021-999.9863 m/z" />
57 <has_text text="Mass range: 50.0021-999.9863 m/z" /> 59 <has_text text="Peaks: 199718 (about 49930 per sample)" />
58 <has_text text="Peaks: 199718 (about 49930 per sample)" /> 60 <has_text text="Peak Groups: 48958" />
59 <has_text text="Peak Groups: 48958" /> 61 <has_text text="Sample classes: bio, blank" />
60 <has_text text="Sample classes: bio, blank" /> 62 </assert_stdout>
61 </assert_contents>
62 </output>
63 </test>--> 63 </test>-->
64 <!-- Issue with fillpeaks because it seems that there are too many NA
64 <test> 65 <test>
65 <param name="image" value="faahKO.xset.group.retcor.group.RData"/> 66 <param name="image" value="faahKO.xset.group.retcor.group.RData"/>
66 <param name="method" value="chrom"/> 67 <param name="method" value="chrom"/>
67 <conditional name="peaklist"> 68 <conditional name="peaklist">
69 <param name="peaklistBool" value="true" />
68 <param name="convertRTMinute" value="false" /> 70 <param name="convertRTMinute" value="false" />
69 <param name="peaklistBool" value="true" />
70 <param name="numDigitsMZ" value="4" /> 71 <param name="numDigitsMZ" value="4" />
71 <param name="numDigitsRT" value="1" /> 72 <param name="numDigitsRT" value="1" />
72 </conditional> 73 </conditional>
73 <expand macro="test_file_load_zip"/> 74 <expand macro="test_file_load_zip"/>
74 <output name="log"> 75 <assert_stdout>
75 <assert_contents> 76 <has_text text="object with 4 samples" />
76 <has_text text="object with 4 samples" /> 77 <has_text text="Time range: 2509.2-4480.3 seconds (41.8-74.7 minutes)" />
77 <has_text text="Time range: 2506-4484 seconds (41.8-74.7 minutes)" /> 78 <has_text text="Mass range: 200.1-600 m/z" />
78 <has_text text="Mass range: 200.1-600 m/z" /> 79 <has_text text="Peaks: 32720 (about 8180 per sample)" />
79 <has_text text="Peaks: 32720 (about 8180 per sample)" /> 80 <has_text text="Peak Groups: 8209" />
80 <has_text text="Peak Groups: 8157" /> 81 <has_text text="Sample classes: KO, WT" />
81 <has_text text="Sample classes: KO, WT" /> 82 </assert_stdout>
82 </assert_contents>
83 </output>
84 <output name="variableMetadata" file="faahKO.xset.group.retcor.group.fillPeaks.variableMetadata.tsv" /> 83 <output name="variableMetadata" file="faahKO.xset.group.retcor.group.fillPeaks.variableMetadata.tsv" />
85 <output name="dataMatrix" file="faahKO.xset.group.retcor.group.fillPeaks.dataMatrix.tsv" /> 84 <output name="dataMatrix" file="faahKO.xset.group.retcor.group.fillPeaks.dataMatrix.tsv" />
86 </test> 85 </test>
87 <test> 86 <test>
88 <param name="image" value="faahKO-single.xset.merged.group.retcor.group.RData"/> 87 <param name="image" value="faahKO-single.xset.merged.group.retcor.group.RData"/>
89 <param name="method" value="chrom"/> 88 <param name="method" value="chrom"/>
90 <conditional name="peaklist"> 89 <conditional name="peaklist">
90 <param name="peaklistBool" value="true" />
91 <param name="convertRTMinute" value="false" /> 91 <param name="convertRTMinute" value="false" />
92 <param name="peaklistBool" value="true" />
93 <param name="numDigitsMZ" value="4" /> 92 <param name="numDigitsMZ" value="4" />
94 <param name="numDigitsRT" value="1" /> 93 <param name="numDigitsRT" value="1" />
95 </conditional> 94 </conditional>
96 <expand macro="test_file_load_single"/> 95 <expand macro="test_file_load_single"/>
97 <output name="log"> 96 <assert_stdout>
98 <assert_contents> 97 <has_text text="object with 4 samples" />
99 <has_text text="object with 4 samples" /> 98 <has_text text="Time range: 2509.2-4480.3 seconds (41.8-74.7 minutes)" />
100 <has_text text="Time range: 2506-4484 seconds (41.8-74.7 minutes)" /> 99 <has_text text="Mass range: 200.1-600 m/z" />
101 <has_text text="Mass range: 200.1-600 m/z" /> 100 <has_text text="Peaks: 32720 (about 8180 per sample)" />
102 <has_text text="Peaks: 32720 (about 8180 per sample)" /> 101 <has_text text="Peak Groups: 8209" />
103 <has_text text="Peak Groups: 8157" /> 102 <has_text text="Sample classes: KO, WT" />
104 <has_text text="Sample classes: KO, WT" /> 103 </assert_stdout>
105 </assert_contents>
106 </output>
107 <output name="variableMetadata" file="faahKO.xset.group.retcor.group.fillPeaks.variableMetadata.tsv" /> 104 <output name="variableMetadata" file="faahKO.xset.group.retcor.group.fillPeaks.variableMetadata.tsv" />
108 <output name="dataMatrix" file="faahKO.xset.group.retcor.group.fillPeaks.dataMatrix.tsv" /> 105 <output name="dataMatrix" file="faahKO.xset.group.retcor.group.fillPeaks.dataMatrix.tsv" />
106 </test>-->
107 <test>
108 <param name="image" value="faahKO-single.xset.merged.group2.retcor2.group2.RData"/>
109 <conditional name="peaklist">
110 <param name="peaklistBool" value="true" />
111 <param name="convertRTMinute" value="false" />
112 <param name="numDigitsMZ" value="4" />
113 <param name="numDigitsRT" value="1" />
114 </conditional>
115 <expand macro="test_file_load_single"/>
116 <assert_stdout>
117 <has_text text="expandMz: 0" />
118 <has_text text="expandRt: 0" />
119 <has_text text="object with 4 samples" />
120 <has_text text="Time range: 2499.4-4473.6 seconds (41.7-74.6 minutes)" />
121 <has_text text="Mass range: 200.1-600 m/z" />
122 <has_text text="Peaks: 15230 (about 3808 per sample)" />
123 <has_text text="Peak Groups: 6332" />
124 <has_text text="Sample classes: KO, WT" />
125 </assert_stdout>
126 <output name="variableMetadata" file="faahKO.xset.group2.retcor2.group2.fillPeaks2.variableMetadata.tsv" />
127 <output name="dataMatrix" file="faahKO.xset.group2.retcor2.group2.fillPeaks2.dataMatrix.tsv" />
109 </test> 128 </test>
110 </tests> 129 </tests>
111 130
112 <help><![CDATA[ 131 <help><![CDATA[
113 132
114 @HELP_AUTHORS@ 133 @HELP_AUTHORS@
115 134
116 ============== 135 ===================
117 Xcms.fillPeaks 136 xcms fillChromPeaks
118 ============== 137 ===================
119 138
120 ----------- 139 -----------
121 Description 140 Description
122 ----------- 141 -----------
123 142
124 **Integrate areas of missing peaks** 143 **Integrate areas of missing peaks**
125 For each sample, identify peak groups where that sample is not 144 For each sample, identify peak groups where that sample is not
126 represented. For each of those peak groups, integrate the signal 145 represented. For each of those peak groups, integrate the signal
127 in the region of that peak group and create a new peak. 146 in the region of that peak group and create a new peak.
128
129 According to the type of raw-data there are 2
130 different methods available. for filling gcms/lcms data the method
131 "chrom" integrates raw-data in the chromatographic domain, whereas
132 "MSW" is used for peaklists without retention-time information
133 like those from direct-infusion spectra.
134 147
135 148
136 149
137 ----------------- 150 -----------------
138 Workflow position 151 Workflow position
180 193
181 ---------- 194 ----------
182 Parameters 195 Parameters
183 ---------- 196 ----------
184 197
185 198 | See the fillChromPeaks_manual_
186 Method 199
187 ------ 200 .. _fillChromPeaks_manual: https://rdrr.io/bioc/xcms/man/fillChromPeaks.html
188 201
189 **chrom** 202 @HELP_XCMS_MANUAL@
190 203
191 | This method produces intensity values for those missing samples by integrating raw data in peak group region. In a given group, the start and ending retention time points for integration are defined by the median start and end points of the other detected peaks. The start and end m/z values are similarly determined. Intensities can be still be zero, which is a rather unusual intensity for a peak. This is the case if e.g. the raw data was threshholded, and the integration area contains no actual raw intensities, or if one sample is miscalibrated, such the raw data points are (just) outside the integration area. 204 @HELP_PEAKLIST@
192 | Importantly, if retention time correction data is available, the alignment information is used to more precisely integrate the propper region of the raw data. If the corrected retention time is beyond the end of the raw data, the value will be not-a-number (NaN).
193
194 **MSW**
195
196 | "MSW" is used for peaklists without retention-time information like those from direct-infusion spectra.
197
198
199 Get a Peak List
200 ---------------
201
202 If 'true', the module generates two additional files corresponding to the peak list:
203 - the variable metadata file (corresponding to information about extracted ions such as mass or retention time)
204 - the data matrix (corresponding to related intensities)
205
206 **decimal places for [mass or retention time] values in identifiers**
207
208 | Ions' identifiers are constructed as MxxxTyyy where 'xxx' is the ion median mass and 'yyy' the ion median retention time.
209 | Two parameters are used to adjust the number of decimal places wanted in identifiers for mass and retention time respectively.
210 | Theses parameters do not affect decimal places in columns other than the identifier one.
211
212 **Reported intensity values**
213
214 | This parameter determines which values should be reported as intensities in the dataMatrix table; it correspond to xcms 'intval' parameter:
215 | - into: integrated area of original (raw) peak
216 | - maxo: maximum intensity of original (raw) peak
217 | - intb: baseline corrected integrated peak area (only available if peak detection was done by ‘findPeaks.centWave’)
218 205
219 ------------ 206 ------------
220 Output files 207 Output files
221 ------------ 208 ------------
222 209
266 --------------------------------------------------- 253 ---------------------------------------------------
267 254
268 Changelog/News 255 Changelog/News
269 -------------- 256 --------------
270 257
258 **Version 3.0.0.0 - 14/02/2018**
259
260 - UPGRADE: upgrade the xcms version from 1.46.0 to 3.0.0. So refactoring of a lot of underlining codes and methods
261
262 - UPDATE: since xcms 3.0.0, the selection of a method is no more needed (chrom or MSW)
263
264 - UPDATE: since xcms 3.0.0, new parameters are available: expandMz, expandRt and ppm
265
271 **Version 2.1.1 - 29/11/2017** 266 **Version 2.1.1 - 29/11/2017**
272 267
273 - BUGFIX: To avoid issues with accented letter in the parentFile tag of the mzXML files, we changed a hidden mechanim to LC_ALL=C 268 - BUGFIX: To avoid issues with accented letter in the parentFile tag of the mzXML files, we changed a hidden mechanim to LC_ALL=C
274 269
275 **Version 2.1.0 - 07/02/2017** 270 **Version 2.1.0 - 07/02/2017**