0
+ − 1 <tool id="lookup_library" name="RIQC-Lookup RI for CAS numbers in library" version="1.0.2">
+ − 2 <description>Lookup or estimate the RI using a "known RI values" CAS numbers library</description>
+ − 3 <command interpreter="python">
+ − 4 library_lookup.py
+ − 5 $library_file
+ − 6 $input
+ − 7 "$col_type"
+ − 8 "$polarity"
+ − 9 $output
+ − 10 #for $ctype in $pref
+ − 11 ${ctype.columntype}
+ − 12 #end for
+ − 13 $regression.model
+ − 14 </command>
+ − 15 <inputs>
41
+ − 16 <!-- Regarding the <page> items: this blocks the use of this tool in Galaxy workflows. However,
+ − 17 alternatives like wrapping this in conditionals, repeats (to force a refresh_on_change as this option
+ − 18 is not working on its own) failed since the workflow editor does not support refreshes...not does the
+ − 19 workflow runtime support conditionals or repeats to be set at runtime. See also
+ − 20 galaxy-dev mail thread "when else" in <conditional> ? RE: refresh_on_change : is this a valid attribute? Any other ideas/options??" -->
0
+ − 21 <page>
+ − 22 <param format="tabular" name="input" type="data" label="NIST identifications as tabular file"
+ − 23 help="Select a tab delimited NIST metabolite identifications file (converted from PDF)" />
+ − 24 <param name="library_file" type="select" label="CAS x RI Library file"
+ − 25 help="Select a library/lookup file containing RI values for CAS numbers on various chromatography columns "
+ − 26 dynamic_options='get_directory_files("tool-data/shared/PRIMS-metabolomics/RI_DB_libraries")'/>
41
+ − 27 </page>
+ − 28 <page>
0
+ − 29 <param name="col_type" type="select" label="Select column type" refresh_on_change="true"
+ − 30 display="radio" dynamic_options='get_column_type(library_file)'
+ − 31 help="" />
41
+ − 32 </page>
0
+ − 33 <page>
+ − 34 <param name="polarity" type="select" label="Select polarity" refresh_on_change="true"
+ − 35 display="radio" dynamic_options='filter_column(library_file,col_type)'
+ − 36 help="" />
+ − 37 </page>
+ − 38 <page>
+ − 39 <conditional name="regression">
+ − 40 <param name="regression_select" type="boolean" checked="false" label="Apply regression method"
+ − 41 help="If no data for the selected column is present in the database, selecting this option will try
+ − 42 to convert Retention Indices using data from other GC-columns with a regression method. Please
+ − 43 note that only the first given GC-column above will be used for this, any alternatives will be
+ − 44 ignored" />
+ − 45 <when value="true">
+ − 46 <param name="model" format="tabular" type="data" label="Tabular file containing regression model"
+ − 47 help="This file contains the coefficients used to perform the regression from one GC-column
+ − 48 to another GC-column"/>
+ − 49 </when>
+ − 50 <when value="false">
+ − 51 <param name="model" type="hidden" value="False" />
+ − 52 </when>
+ − 53 </conditional>
+ − 54 <repeat name="pref" title="Select column name preference">
+ − 55 <param name="columntype" type="select" label="Column name" refresh_on_change="true"
+ − 56 dynamic_options='filter_column2(library_file, col_type, polarity)'
+ − 57 help="Select one or more column names for filtering. The order defines the priority." />
+ − 58 </repeat>
+ − 59 </page>
+ − 60 </inputs>
+ − 61 <outputs>
+ − 62 <data format="tabular" label="${tool.name} on" name="output" />
+ − 63 </outputs>
+ − 64 <code file="match_library.py" />
+ − 65 <help>
+ − 66 Performs a lookup of the RI values by matching CAS numbers from the given NIST identifications file to a library.
+ − 67 If a direct match is NOT found for the preferred column name, a regression can be done to find
+ − 68 the theoretical RI value based on known RI values for the CAS number on other column types (see step 4).
+ − 69 If there is no match for the CAS number on any column type, then the record is not given a RI.
+ − 70
+ − 71
+ − 72
+ − 73 </help>
+ − 74
+ − 75 </tool>