comparison rpfba.xml @ 0:12689dfad4d1 draft

"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rpfba commit fa5ae809fac45d020ee3f069f775f0f7f7c2c70b"
author iuc
date Mon, 17 Jan 2022 11:55:50 +0000
parents
children 19be43e96154
comparison
equal deleted inserted replaced
-1:000000000000 0:12689dfad4d1
1 <tool id="rpfba" name="Flux balance analysis" version="@TOOL_VERSION@" profile="19.09">
2 <description>for the RetroPath2.0 heterologous pathways</description>
3 <macros>
4 <token name="@TOOL_VERSION@">5.11.1</token>
5 </macros>
6 <requirements>
7 <requirement type="package" version="@TOOL_VERSION@">rptools</requirement>
8 </requirements>
9 <stdio>
10 <regex match="WARNING" level="warning" />
11 <regex match="ERROR" level="fatal" />
12 </stdio>
13 <command detect_errors="exit_code"><![CDATA[
14 python -m rptools.rpfba '$pathway' '$model' '$compartment_id' '$pathway_with_fba'
15 #if str($adv.merge) == "true":
16 --merge
17 #end if
18 --objective_rxn_id '$input_sim_type.objective_rxn_id'
19 --sim '$input_sim_type.sim_type'
20 #if str($adv.ignore_orphan_species) == "true":
21 --ignore_orphan_species
22 #end if
23 --log "error"
24 #if str($input_sim_type.sim_type)=="fraction"
25 --biomass_rxn_id '$biomass_rxn_id'
26 --fraction_of '$input_sim_type.fraction_of'
27 #end if
28 #if str($input_sim_type.sim_type)=="pfba"
29 --biomass_rxn_id '$biomass_rxn_id'
30 --fraction_of '$input_sim_type.fraction_of'
31 #end if
32 #if str($input_sim_type.sim_type)=="fba"
33 --biomass_rxn_id '$biomass_rxn_id'
34 --fraction_of 0.0
35 #end if
36 ]]></command>
37 <inputs>
38 <param name="pathway" type="data" format="sbml" label="Pathway (rpSBML)" />
39 <param name="model" type="data" format="sbml" label="Model (SBML)" />
40 <param name="compartment_id" type="text" label="SBML compartment ID" value="MNXC3" >
41 <validator type="empty_field" message="A compartment ID is required"/>
42 </param>
43 <conditional name="input_sim_type">
44 <param name="sim_type" type="select" label="Constraint based simulation type">
45 <option value="fraction" selected="true">Fraction of Reaction</option>
46 <option value="fba" >FBA</option>
47 <option value="pfba">Parsimonious FBA</option>
48 </param>
49 <when value="fraction">
50 <param name="fraction_of" type="float" value="0.75" min="0" max="1.0" label="Fraction of the optimum" />
51 <param name="objective_rxn_id" type="text" value="rxn_target" label="reaction ID to optimise" >
52 <validator type="empty_field" message="Reaction ID is required"/>
53 </param>
54 </when>
55 <when value="pfba">
56 <param name="fraction_of" type="float" value="0.95" min="0" max="1.0" label="Fraction of the optimum" />
57 <param name="objective_rxn_id" type="text" value="rxn_target" label="reaction ID to optimise" >
58 <validator type="empty_field" message="Reaction ID is required"/>
59 </param>
60 </when>
61 <when value="fba">
62 <param name="objective_rxn_id" type="text" value="rxn_target" label="reaction ID to optimise" >
63 <validator type="empty_field" message="Reaction ID is required"/>
64 </param>
65 </when>
66 </conditional>
67 <param name="biomass_rxn_id" type="text" value="biomass" label="biomass reaction ID" >
68 <validator type="empty_field" message="Biomass reaction ID is required"/>
69 </param>
70 <section name="adv" title="Advanced Options" expanded="false">
71 <param name="merge" type="boolean" label="Output the merged model?" checked="false" display="checkboxes" />
72 <param name="ignore_orphan_species" type="boolean" label="Ignore metabolites that are only consumed or produced?" checked="true" />
73 </section>
74 </inputs>
75 <outputs>
76 <data name="pathway_with_fba" format="sbml" label="${tool.name}(${input_sim_type.sim_type}) - ${pathway.name}" />
77 </outputs>
78 <tests>
79 <test>
80 <!-- test 1: check if identical outputs are produced with R_BIOMASS__3 biomass name ID and BiGG model (iCN718) -->
81 <param name="pathway" value="rp_001_0001.xml" />
82 <param name="model" value="iCN718.xml.gz" />
83 <param name="biomass_rxn_id" value="R_BIOMASS__3" />
84 <output name="pathway_with_fba" >
85 <assert_contents>
86 <is_valid_xml />
87 <!--check fba_fraction value-->
88 <has_text text="5.54302" />
89 <!--check fba_biomass value-->
90 <has_text text="1.31359" />
91 <has_n_lines n="408" />
92 </assert_contents>
93 </output>
94 </test>
95 <test>
96 <!-- test 2: check if identical outputs are produced with R_BIOMASS__3 biomass name ID and BiGG model (iCN718) and sim_type=fba-->
97 <param name="pathway" value="rp_001_0001.xml" />
98 <param name="model" value="iCN718.xml.gz" />
99 <param name="biomass_rxn_id" value="R_BIOMASS__3" />
100 <conditional name="input_sim_type">
101 <param name="sim_type" value="fba"/>
102 </conditional>
103 <output name="pathway_with_fba" >
104 <assert_contents>
105 <is_valid_xml />
106 <!--check fba_fba value-->
107 <has_text text="16.47058" />
108 <not_has_text text="fba_fraction" />
109 <has_n_lines n="392" />
110 </assert_contents>
111 </output>
112 </test>
113 <test>
114 <!-- test 3: check if identical outputs are produced with R_DM_biomass_c biomass name ID and BiGG model (iCN718) and sim_type=pfba-->
115 <param name="pathway" value="rp_001_0001.xml" />
116 <param name="model" value="iCN718.xml.gz" />
117 <param name="biomass_rxn_id" value="R_DM_biomass_c" />
118 <conditional name="input_sim_type">
119 <param name="sim_type" value="pfba"/>
120 </conditional>
121 <output name="pathway_with_fba" >
122 <assert_contents>
123 <is_valid_xml />
124 <!--check fba_pfba value-->
125 <has_text text="2623.54248" />
126 <not_has_text text="fba_fraction" />
127 <has_n_lines n="392" />
128 </assert_contents>
129 </output>
130 </test>
131 </tests>
132 <help><![CDATA[
133 FBA
134 =====
135
136
137 Flux balance analysis is a mathematical approach for analyzing the flow of metabolites through a metabolic network. It is performed for heterologous pathways generated by RetroPath2.0. The tool performs the following steps:
138
139 - Merges a user-defined GEM SBML model with each given heterologous pathway individually.
140 - Performs FBA using the CobraPy package. Three different analysis methods are proposed; two of which are native CobraPy methods - standard FBA and Parsimonious FBA, the other one proposed is an in-house analysis method named "Fraction of Reaction".
141
142 The "Fraction of Reaction" method involves performing FBA using the "Source Reaction" as the objective function (by default the biomass reaction is specified, which refers to the rate at which all of the biomass precursors are made in the correct proportions). Then the flux of that reaction has its upper and lower bounds set to the same value, determined as a "Fraction of the source reaction" (default is 75% of its optimum). Thereafter, the objective is set to the target reaction followed by performing FBA once again. The tool uses the FBC package to manage the objective and flux bounds.
143 For the first two, the user must specify the name(s) of reaction(s) that the model will optimize to, while for the latter the user must provide the target reaction but also another source reaction that will be restricted.
144 Using the Advanced Options, the user can specify the name of the heterologous pathway as created by "Pathways to SBML" and the compartment ID of the heterologous pathway. The user may obtain a merged version of the resulting model, or the heterologous pathway only using the "output the merged model ?" boolean parameter. Using the "Maximize the Objective?", the user may choose to maximize or minimize the objective (biomass production in this case) in the model.
145
146 NOTE: In order to FBA works correctly, some of chemical species have to be ignored. These species are selected according to the following criteria:
147
148 - pathway species has not been found in the model (neither by its ID nor its InChIKey),
149 - the species is not the target, and
150 - the species is only consumed or produced with the heterologue pathway.
151
152 .. image:: https://raw.githubusercontent.com/Galaxy-SynBioCAD/rpFBA/standalone/galaxy/img/rpFBA.png
153 :width: 60 %
154 :align: center
155
156 |
157
158 The above figure illustrates the steps in the tool's calculation of FBA. The pathway is merged with a GEM SBML model and using the FBC package and CobraPy FBA is performed and the fluxes saved to the SBML file.
159
160 Input
161 -----
162
163 Required:
164
165
166 * **pathway_file**\ : (string) SBML file that contains an heterologous pathway
167 * **model_filel**\ : (string) Path to the GEM SBML model
168 * **compartment_id**\ : (string) Model compartment id (e.g. 'c' or 'MNXC3')
169 * **outfile**\ : (string) Path to the output file
170
171 Advanced options:
172
173
174 * **--sim**\ : (string, default=fraction) Valid options include: fraction, fba, pfba. The type of constraint based modelling method
175 * **--biomass_rxn_id**\ : (string, default=biomass) biomass reaction ID that will be restricted in the "fraction" simulation type. This parameter is ignored for "fba" and "pfba"
176 * **--objective_rxn_id**\ : (string, default=rxn_target) reaction ID to optimise. This parameters is required in all simulation type
177 * **--fraction_of**\ : (float, default=0.75) Portion of the maximal flux used to set the maximal and minimal bounds for the source reaction of the "fraction" simulation type
178 * **--merge**\ : (boolean, default=False) output the full merged model instead of heterologous pathway only
179 * **--ignore_orphan_species**\ : (boolean, default=True) ignore metabolites that are only consumed or produced
180 * **--log**: (string, default=error) Set the log level, choices are 'debug', 'info', 'warning', 'error', 'critical'
181
182
183 Project Links
184 ---------------------
185
186 * `GitHub <https://github.com/brsynth/rptools/tree/master/rptools/rpfba>`_
187
188 Version
189 ----------
190
191 5.11.1
192
193 Authors
194 -------
195
196 * **Melchior du Lac**
197 * **Joan Hérisson**
198
199 License
200 -------
201
202 `MIT <https://github.com/brsynth/rptools/blob/master/LICENSE>`_
203
204 Acknowledgments
205 ---------------
206
207 * Thomas Duigou
208 ]]></help>
209 <citations>
210 <citation type="doi">10.1186/1752-0509-7-74</citation>
211 <citation type="doi">10.1515/jib-2016-290 </citation>
212 </citations>
213 </tool>