annotate cobraxy-9688ad27287b/COBRAxy/ras_to_bounds.xml @ 90:a48b2e06ebe7 draft

Uploaded
author luca_milaz
date Sun, 13 Oct 2024 11:35:56 +0000
parents
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
90
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
1 <tool id="MaREA RAS to bounds" name="RAStoBounds" version="2.0.0">
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
2
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
3 <macros>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
4 <import>marea_macros.xml</import>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
5 </macros>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
6
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
7 <requirements>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
8 <requirement type="package" version="1.24.4">numpy</requirement>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
9 <requirement type="package" version="2.0.3">pandas</requirement>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
10 <requirement type="package" version="0.29.0">cobra</requirement>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
11 <requirement type="package" version="5.2.2">lxml</requirement>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
12 <requirement type="package" version="1.4.2">joblib</requirement>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
13 </requirements>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
14
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
15 <command detect_errors="exit_code">
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
16 <![CDATA[
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
17 python $__tool_directory__/ras_to_bounds.py
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
18 --tool_dir $__tool_directory__
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
19 --model_selector $cond_model.model_selector
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
20 --cell_class $cell_class
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
21 #if $cond_model.model_selector == 'Custom'
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
22 --model $model
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
23 --model_name $model.element_identifier
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
24 #end if
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
25 --medium_selector $cond_medium.medium_selector
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
26 #if $cond_medium.medium_selector == 'Custom'
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
27 --medium $medium
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
28 #end if
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
29 --ras_selector $cond_ras.ras_choice
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
30 #if $cond_ras.ras_choice == "True"
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
31 --input_ras $cond_ras.input_ras
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
32 --classes $cond_ras.classes
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
33 #end if
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
34 --out_log $log
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
35 ]]>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
36 </command>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
37 <inputs>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
38 <conditional name="cond_model">
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
39 <expand macro="options_ras_to_bounds_model"/>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
40 <when value="Custom">
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
41 <param name="model" argument="--model" type="data" format="json, xml" label="Custom model" />
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
42 </when>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
43 </conditional>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
44
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
45 <conditional name="cond_ras">
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
46 <param name="ras_choice" argument="--ras_choice" type="select" label="Do want to use RAS?">
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
47 <option value="True" selected="true">Yes</option>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
48 <option value="False">No</option>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
49 </param>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
50 <when value="True">
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
51 <param name="input_ras" argument="--input_ras" multiple="true" type="data" format="tabular, csv, tsv" label="RAS matrix:" />
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
52 <param name="classes" argument="--classes" type="text" value="None" label="Classes:" help="Write here the the classes to assign to each of the uploaded RAS matrices. Example for two RAS matrices:'cellNormal, cellCancer'. If you uploaded just one matrix, leave default value." />
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
53 </when>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
54 </conditional>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
55
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
56 <conditional name="cond_medium">
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
57 <expand macro="options_ras_to_bounds_medium"/>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
58 <when value="Custom">
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
59 <param name="medium" argument="--medium" type="data" format="tabular, csv, tsv" label="Custom medium" />
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
60 </when>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
61 </conditional>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
62
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
63 </inputs>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
64
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
65 <outputs>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
66 <data format="txt" name="log" label="RAStoBounds- Log" />
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
67 <data format="tabular" name="cell_class" label="RAStoBounds - Cells class" />
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
68 <collection name="ras_to_bounds" type="list" label="Ras to Bounds">
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
69 <discover_datasets name = "collection" pattern="__name_and_ext__" directory="ras_to_bounds"/>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
70 </collection>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
71
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
72 </outputs>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
73
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
74 <help>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
75
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
76 <![CDATA[
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
77
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
78 What it does
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
79 -------------
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
80
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
81 This tool generates the reactions bounds for a given metabolic model (JSON or XML format) both with and without the use of the Reaction Activity Scores (RAS) matrix generated by RAS generator.
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
82 Moreover, it enables to use custom/pre-defined growth mediums to constrain exchange reactions. For a custom medium, It is suggested to use the template file returned by the Custom Data Generator tool.
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
83 If the RAS matrix, generated by the RAS generator tool, is used, then a bounds file is generated for each cell. Otherwise, a single bounds file is returned.
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
84
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
85 Accepted files:
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
86 - A model: JSON or XML file reporting reactions and rules contained in the model.
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
87 - RAS matrix: tab-separated RAS file as returned by RAS generator. It can be a collection of RAS files too (e.g. one RAS matrix for normal cells and one for cancer cells). Note that if multiple RAs matrices are uploaded, the bounds are normalzed across all cells.
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
88 - Classes: If multiple RAS matrices are uploaded, then the tool returns a simple file containing for each cell the class it belongs to (cells coming from the same RAS matrix are assigned to the same class). This file is useful in the Flux enrichment analysis tool.
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
89 - Medium: tab-separated file containing lower and upper-bounds of medium reactions.
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
90
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
91 Example of custum growth medium file:
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
92
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
93
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
94 +------------+----------------+----------------+
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
95 | Reaction ID| lower_bound | upper_bound |
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
96 +============+================+================+
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
97 | r1 | 0.123167 | 0.371355 |
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
98 +------------+----------------+----------------+
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
99 | r2 | 0.268765 | 0.765567 |
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
100 +------------+----------------+----------------+
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
101
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
102
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
103 Output:
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
104 -------------
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
105
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
106 The tool generates:
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
107 - bounds: reporting the bounds of the model, or cells if RAS is used. Format: tab-separated.
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
108 - Classes: a file containing the class of each cell (only if multiple RAS matrices were uploaded). Format: tab-separated.
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
109 - a log file (.txt).
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
110 ]]>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
111 </help>
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
112 <expand macro="citations" />
a48b2e06ebe7 Uploaded
luca_milaz
parents:
diff changeset
113 </tool>