view library_lookup.xml @ 24:385d21a8d0a0

New tool to Query multiple public repositories for elemental compositions from accurate mass values detected by high-resolution mass spectrometers
author pieter.lukasse@wur.nl
date Thu, 03 Apr 2014 16:50:45 +0200
parents 9d5f4f5f764b
children e67149fbff20
line wrap: on
line source

<tool id="lookup_library" name="RIQC-Lookup RI for CAS numbers in library" version="1.0.2">
  <description>Lookup or estimate the RI using a "known RI values" CAS numbers library</description>
  <command interpreter="python">
    library_lookup.py 
    $library_file
    $input 
    "$col_type" 
    "$polarity" 
    $output
    #for $ctype in $pref
      ${ctype.columntype}
    #end for
    $regression.model	
  </command>
  <inputs>
    <page>
      <param format="tabular" name="input" type="data" label="NIST identifications as tabular file" 
      		 help="Select a tab delimited NIST metabolite identifications file (converted from PDF)" />
      <param name="library_file" type="select" label="CAS x RI Library file" 
      		 help="Select a library/lookup file containing RI values for CAS numbers on various chromatography columns " 
      		 dynamic_options='get_directory_files("tool-data/shared/PRIMS-metabolomics/RI_DB_libraries")'/>
      <param name="col_type" type="select" label="Select column type" refresh_on_change="true"
	         display="radio" dynamic_options='get_column_type(library_file)'
	         help="" />
    </page>
    <page>
      <param name="polarity" type="select" label="Select polarity" refresh_on_change="true"
             display="radio" dynamic_options='filter_column(library_file,col_type)'
	         help="" />
    </page>
    <page>
	  <conditional name="regression">
		  <param name="regression_select" type="boolean" checked="false" label="Apply regression method" 
		  		 help="If no data for the selected column is present in the database, selecting this option will try 
		  		 	   to convert Retention Indices using data from other GC-columns with a regression method. Please
		  		 	   note that only the first given GC-column above will be used for this, any alternatives will be
		  		 	   ignored" />
		  <when value="true">
		  	<param name="model" format="tabular" type="data" label="Tabular file containing regression model" 
		  		   help="This file contains the coefficients used to perform the regression from one GC-column
		  		         to another GC-column"/>     
		  </when>
          <when value="false">
            <param name="model" type="hidden" value="False" />
          </when>
	  </conditional>
      <repeat name="pref" title="Select column name preference">
		<param name="columntype" type="select" label="Column name" refresh_on_change="true"
               dynamic_options='filter_column2(library_file, col_type, polarity)'
	       	   help="Select one or more column names for filtering. The order defines the priority." />
      </repeat>
    </page>
  </inputs>
  <outputs>
    <data format="tabular" label="${tool.name} on" name="output" />
</outputs>
<code file="match_library.py" />
  <help>
Performs a lookup of the RI values by matching CAS numbers from the given NIST identifications file to a library.
If a direct match is NOT found for the preferred column name, a regression can be done to find
the theoretical RI value based on known RI values for the CAS number on other column types (see step 4).
If there is no match for the CAS number on any column type, then the record is not given a RI. 



  </help>

</tool>