235
|
1 <tool id="FluxToMap" name="Metabolic Flux Enrichment Analysis" version="2.0.0">
|
194
|
2 <macros>
|
|
3 <import>marea_macros.xml</import>
|
|
4 </macros>
|
|
5
|
|
6 <requirements>
|
|
7 <requirement type="package" version="1.24.4">numpy</requirement>
|
|
8 <requirement type="package" version="2.0.3">pandas</requirement>
|
|
9 <requirement type="package" version="1.10.1">scipy</requirement>
|
|
10 <requirement type="package" version="1.5.1">svglib</requirement>
|
|
11 <requirement type="package" version="2.2.3">pyvips</requirement>
|
|
12 <requirement type="package" version="2.7.1">cairosvg</requirement>
|
|
13 <requirement type="package" version="0.29.0">cobra</requirement>
|
252
|
14 <requirement type="package" version="5.2.2">lxml</requirement>
|
194
|
15 </requirements>
|
|
16
|
|
17 <command detect_errors="exit_code">
|
|
18 <![CDATA[
|
201
|
19 python $__tool_directory__/flux_to_map.py
|
194
|
20
|
|
21 --tool_dir $__tool_directory__
|
|
22 --option $cond.type_selector
|
|
23 --out_log $log
|
|
24
|
|
25 #if $cond.type_selector == 'datasets':
|
|
26
|
242
|
27 --input_datas_fluxes
|
245
|
28 #for $data in $cond.input_datasets_fluxes:
|
242
|
29 ${data.input_fluxes}
|
|
30 #end for
|
194
|
31
|
242
|
32 --names_fluxes
|
245
|
33 #for $data in $cond.input_datasets_fluxes:
|
242
|
34 ${data.input_name_fluxes}
|
|
35 #end for
|
194
|
36
|
|
37 #elif $cond.type_selector == 'dataset_class':
|
|
38
|
243
|
39 --input_data_fluxes $input_data_fluxes
|
|
40 --input_class_fluxes $input_class_fluxes
|
194
|
41
|
|
42 #end if
|
|
43
|
|
44 --comparison ${comparis.comparison}
|
|
45 #if $comparis.comparison == 'onevsmany'
|
|
46 --control '${cond.comparis.controlgroup}'
|
|
47 #end if
|
|
48
|
|
49 --choice_map '${cond_choice_map.choice_map}'
|
|
50 #if $cond_choice_map.choice_map == 'Custom':
|
|
51 --custom_map ${cond_choice_map.custom_map}
|
|
52 #end if
|
|
53
|
|
54 #if $advanced.choice == 'true':
|
|
55 --pValue ${advanced.pValue}
|
|
56 --fChange ${advanced.fChange}
|
|
57 --generate_svg ${advanced.generateSvg}
|
|
58 --generate_pdf ${advanced.generatePdf}
|
|
59 #else
|
|
60 --pValue 0.05
|
|
61 --fChange 1.2
|
|
62 --generate_svg false
|
|
63 --generate_pdf true
|
|
64 #end if
|
|
65 ]]>
|
|
66 </command>
|
|
67
|
|
68 <inputs>
|
235
|
69
|
194
|
70 <conditional name="cond">
|
|
71 <param name="type_selector" argument="--option" type="select" label="Input format:">
|
235
|
72 <option value="datasets" selected="true">Fluxes of group 1 + Fluxes of group 2 + ... + Fluxes of group N</option>
|
|
73 <option value="dataset_class">All fluxes + sample group specification</option>
|
194
|
74 </param>
|
|
75
|
|
76 <when value="datasets">
|
235
|
77 <repeat name="input_datasets_fluxes" title="Fluxes dataset" min="2">
|
242
|
78 <param name="input_fluxes" argument="--input_datas_fluxes" type="data" format="tabular, csv, tsv" label="add dataset" />
|
|
79 <param name="input_name_fluxes" argument="--names_fluxes" type="text" label="Dataset's name:" value="Dataset" help="Default: Dataset" />
|
235
|
80 </repeat>
|
194
|
81 </when>
|
|
82
|
|
83 <when value="dataset_class">
|
242
|
84 <param name="input_data_fluxes" argument="--input_data_fluxes" type="data" format="tabular, csv, tsv" label="All fluxes" />
|
|
85 <param name="input_class_fluxes" argument="--input_class_fluxes" type="data" format="tabular, csv, tsv" label="Sample group specification" />
|
194
|
86 </when>
|
|
87 </conditional>
|
235
|
88
|
194
|
89 <conditional name="comparis">
|
|
90 <param name="comparison" argument="--comparison" type="select" label="Groups comparison:">
|
|
91 <option value="manyvsmany" selected="true">One vs One</option>
|
|
92 <option value="onevsrest">One vs All</option>
|
|
93 <option value="onevsmany">One vs Control</option>
|
|
94 </param>
|
|
95 <when value="onevsmany">
|
|
96 <param name="controlgroup" argument="--controlgroup" type="text" label="Control group label:" value="0" help="Name of group label to be compared to others"/>
|
|
97 </when>
|
|
98 </conditional>
|
|
99
|
|
100 <conditional name="cond_choice_map">
|
|
101 <param name="choice_map" argument="--choice_map" type="select" label="Choose metabolic map:">
|
|
102 <option value="HMRcore" selected="true">HMRcore</option>
|
|
103 <option value="ENGRO2">ENGRO2</option>
|
|
104 <option value="Custom">Custom</option>
|
|
105 </param>
|
|
106
|
|
107 <when value="Custom">
|
|
108 <param name="custom_map" argument="--custom_map" type="data" format="xml, svg" label="custom-map.svg"/>
|
|
109 </when>
|
|
110 </conditional>
|
235
|
111
|
194
|
112 <conditional name="advanced">
|
|
113 <param name="choice" type="boolean" checked="false" label="Use advanced options?" help="Use this options to choose custom parameters for evaluation: pValue, Fold-Change threshold, how to solve (A and NaN) and specify output maps.">
|
|
114 <option value="true" selected="true">No</option>
|
|
115 <option value="false">Yes</option>
|
|
116 </param>
|
|
117
|
|
118 <when value="true">
|
|
119 <param name="pValue" argument="--pValue" type="float" size="20" value="0.05" max="1" min="0" label="P-value threshold:" help="min value 0" />
|
|
120 <param name="fChange" argument="--fChange" type="float" size="20" value="1.2" min="1" label="Fold-Change threshold:" help="min value 1" />
|
|
121 <param name="generateSvg" argument="--generateSvg" type="boolean" checked="false" label="Generate SVG map" help="should the program generate an editable svg map of the processes?" />
|
|
122 <param name="generatePdf" argument="--generatePdf" type="boolean" checked="true" label="Generate PDF map" help="should the program return a non editable (but displayble) pdf map of the processes?" />
|
|
123 </when>
|
|
124 </conditional>
|
|
125 </inputs>
|
|
126
|
|
127 <outputs>
|
242
|
128 <data format="txt" name="log" label="FluxToMap - Log" />
|
|
129 <collection name="results" type="list" label="FluxToMap - Results">
|
194
|
130 <discover_datasets pattern="__name_and_ext__" directory="result"/>
|
|
131 </collection>
|
|
132 </outputs>
|
|
133
|
|
134 <help>
|
|
135 <![CDATA[
|
|
136
|
|
137 What it does
|
|
138 -------------
|
|
139
|
|
140 This tool analyzes and visualizes differences in the Reaction Activity Scores (RASs) of groups of samples, as computed by the Expression2RAS tool, of groups of samples.
|
|
141
|
|
142 Accepted files are:
|
|
143 - option 1) two or more RAS datasets, each referring to samples in a given group. The user can specify a label for each group (as e.g. "classA" and "classB");
|
|
144 - option 2) one RAS dataset and one group-file specifying the group each sample belongs to.
|
|
145
|
|
146 RAS datasets format: tab-separated text files, reporting the RAS value of each reaction (row) for a given sample (column).
|
|
147
|
|
148 Column header: sample ID.
|
|
149 Row header: reaction ID.
|
|
150
|
|
151 Optional files:
|
|
152 - custom svg map. Graphical elements must have the same IDs of reactions. See HmrCore svg map for an example.
|
|
153
|
|
154 The tool generates:
|
|
155 - 1) a tab-separated file: reporting fold-change and p-values of reaction activity scores (RASs) between a pair of conditions/classes;
|
|
156 - 2) a metabolic map file (downloadable as .svg): visualizing up- and down-regulated reactions between a pair of conditions/classes;
|
|
157 - 3) a log file (.txt).
|
|
158
|
|
159 Output options:
|
|
160 To calculate P-Values and Fold-Changes and to enrich maps, comparisons are performed for each possible pair of groups (default option ‘One vs One’).
|
|
161
|
|
162 Alternative options are:
|
|
163 - comparison of each group vs. the rest of samples (option ‘One vs Rest’)
|
|
164 - comparison of each group vs. a control group (option ‘One vs Control). If this option is selected the user must indicate the control group label.
|
|
165
|
|
166 Output files will be named as classA_vs_classB. Reactions will conventionally be reported as up-regulated (down-regulated) if they are significantly more (less) active in class having label "classA".
|
|
167
|
|
168 Example input
|
|
169 -------------
|
|
170
|
|
171 "RAS of group 1 + RAS of group 2 + ... + RAS of group N" option:
|
|
172
|
|
173 RAS Dataset 1:
|
|
174
|
|
175 +------------+----------------+----------------+----------------+
|
|
176 | Reaction ID| TCGAA62670 | TCGAA62671 | TCGAA62672 |
|
|
177 +============+================+================+================+
|
|
178 | r1642 | 0.523167 | 0.371355 | 0.925661 |
|
|
179 +------------+----------------+----------------+----------------+
|
|
180 | r1643 | 0.568765 | 0.765567 | 0.456789 |
|
|
181 +------------+----------------+----------------+----------------+
|
|
182 | r1640 | 0.876545 | 0.768933 | 0.987654 |
|
|
183 +------------+----------------+----------------+----------------+
|
|
184 | r1641 | 0.456788 | 0.876543 | 0.876542 |
|
|
185 +------------+----------------+----------------+----------------+
|
|
186 | r1646 | 0.876543 | 0.786543 | 0.897654 |
|
|
187 +------------+----------------+----------------+----------------+
|
|
188
|
|
189 RAS Dataset 2:
|
|
190
|
|
191 +------------+----------------+----------------+----------------+
|
|
192 | Reaction ID| TCGAA62670 | TCGAA62671 | TCGAA62672 |
|
|
193 +============+================+================+================+
|
|
194 | r1642 | 0.523167 | 0.371355 | 0.925661 |
|
|
195 +------------+----------------+----------------+----------------+
|
|
196 | r1643 | 0.568765 | 0.765567 | 0.456789 |
|
|
197 +------------+----------------+----------------+----------------+
|
|
198 | r1640 | 0.876545 | 0.768933 | 0.987654 |
|
|
199 +------------+----------------+----------------+----------------+
|
|
200 | r1641 | 0.456788 | 0.876543 | 0.876542 |
|
|
201 +------------+----------------+----------------+----------------+
|
|
202 | r1646 | 0.876543 | 0.786543 | 0.897654 |
|
|
203 +------------+----------------+----------------+----------------+
|
|
204
|
|
205 "RAS of all samples + sample group specification" option:
|
|
206
|
|
207 RAS Dataset:
|
|
208
|
|
209 +------------+----------------+----------------+----------------+
|
|
210 | Reaction ID| TCGAA62670 | TCGAA62671 | TCGAA62672 |
|
|
211 +============+================+================+================+
|
|
212 | r1642 | 0.523167 | 0.371355 | 0.925661 |
|
|
213 +------------+----------------+----------------+----------------+
|
|
214 | r1643 | 0.568765 | 0.765567 | 0.456789 |
|
|
215 +------------+----------------+----------------+----------------+
|
|
216 | r1640 | 0.876545 | 0.768933 | 0.987654 |
|
|
217 +------------+----------------+----------------+----------------+
|
|
218 | r1641 | 0.456788 | 0.876543 | 0.876542 |
|
|
219 +------------+----------------+----------------+----------------+
|
|
220 | r1646 | 0.876543 | 0.786543 | 0.897654 |
|
|
221 +------------+----------------+----------------+----------------+
|
|
222
|
|
223 Group-file
|
|
224
|
|
225 +---------------+-----------+
|
|
226 | Patient ID | Class |
|
|
227 +===============+===========+
|
|
228 | TCGAAA3529 | MSI |
|
|
229 +---------------+-----------+
|
|
230 | TCGAA62671 | MSS |
|
|
231 +---------------+-----------+
|
|
232 | TCGAA62672 | MSI |
|
|
233 +---------------+-----------+
|
|
234
|
|
235 Advanced options
|
|
236 ----------------
|
|
237
|
|
238 P-Value threshold: the threshold used for significance Kolmogorov-Smirnov (KS) test, to verify whether the distributions of RASs over the samples in two sets are significantly different
|
|
239
|
|
240 Fold-Change threshold: threshold of the fold-change between the average RAS of two groups. Among the reactions that pass the KS test, only fold-change values larger than the indicated threshold will be visualized on the output metabolic map;
|
|
241
|
|
242
|
|
243 .. class:: infomark
|
|
244
|
|
245 **TIP**: If your data is not TAB delimited, use `Convert delimiters to TAB`_.
|
|
246
|
|
247 .. class:: infomark
|
|
248
|
|
249 **TIP**: If your dataset is not split into classes, use `MaREA cluster analysis`_.
|
|
250
|
|
251 .. class:: infomark
|
|
252
|
|
253 **TIP**: This tool using the RAS scores computed by `Ras tool`_.
|
|
254
|
|
255 @REFERENCE@
|
|
256
|
|
257 .. _Ras tool: http://bimib.disco.unimib.it:5555/?tool_id=toolshed.g2.bx.psu.edu%2Frepos%2Fbimib%2Fmarea%2FMaREA+RAS+Generator%2F1.0.6&version=1.0.6&__identifer=auulv6gbp76
|
|
258 .. _Convert delimiters to TAB: http://bimib.disco.unimib.it:5555/?tool_id=Convert+characters1&version=1.0.0&__identifer=76g7trea4j6
|
|
259 .. _MaREA cluster analysis: http://bimib.disco.unimib.it:5555/?tool_id=toolshed.g2.bx.psu.edu%2Frepos%2Fbimib%2Fmarea%2FMaREA_cluester%2F1.1.2&version=1.1.2&__identifer=lxbyzn2me9
|
|
260
|
|
261 ]]>
|
|
262 </help>
|
|
263 <expand macro="citations" />
|
|
264 </tool> |