Mercurial > repos > galaxyp > openms_idmassaccuracy
diff IDMassAccuracy.xml @ 11:65be0674bb70 draft
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit 020906fb54bde7fc143c356f41975c378a741315"
author | galaxyp |
---|---|
date | Wed, 09 Sep 2020 20:06:18 +0000 |
parents | 86f5365280dd |
children | 31bc4129f589 |
line wrap: on
line diff
--- a/IDMassAccuracy.xml Fri May 17 10:03:56 2019 -0400 +++ b/IDMassAccuracy.xml Wed Sep 09 20:06:18 2020 +0000 @@ -1,127 +1,136 @@ <?xml version='1.0' encoding='UTF-8'?> <!--This is a configuration file for the integration of a tools into Galaxy (https://galaxyproject.org/). This file was automatically generated using CTDConverter.--> <!--Proposed Tool Section: [Utilities]--> -<tool id="IDMassAccuracy" name="IDMassAccuracy" version="2.3.0"> +<tool id="IDMassAccuracy" name="IDMassAccuracy" version="@TOOL_VERSION@+galaxy@GALAXY_VERSION@" profile="20.05"> <description>Calculates a distribution of the mass error from given mass spectra and IDs.</description> <macros> <token name="@EXECUTABLE@">IDMassAccuracy</token> <import>macros.xml</import> + <import>macros_autotest.xml</import> + <import>macros_test.xml</import> </macros> - <expand macro="references"/> + <expand macro="requirements"/> <expand macro="stdio"/> - <expand macro="requirements"/> - <command detect_errors="aggressive"><![CDATA[IDMassAccuracy + <command detect_errors="exit_code"><![CDATA[@QUOTE_FOO@ +@EXT_FOO@ +#import re --in - #for token in $param_in: - $token - #end for --id_in - #for token in $param_id_in: - $token - #end for -#if $param_precursor_out: - -precursor_out $param_precursor_out +## Preprocessing +mkdir in && +${ ' '.join(["ln -s '%s' 'in/%s.%s' &&" % (_, re.sub('[^\w\-_]', '_', _.element_identifier), $gxy2omsext(_.ext)) for _ in $in if _]) } +mkdir id_in && +${ ' '.join(["ln -s '%s' 'id_in/%s.%s' &&" % (_, re.sub('[^\w\-_]', '_', _.element_identifier), $gxy2omsext(_.ext)) for _ in $id_in if _]) } +#if "out_precursor_FLAG" in str($OPTIONAL_OUTPUTS).split(',') + mkdir out_precursor && +#end if +#if "out_fragment_FLAG" in str($OPTIONAL_OUTPUTS).split(',') + mkdir out_fragment && +#end if +#if "out_precursor_fit_FLAG" in str($OPTIONAL_OUTPUTS).split(',') + mkdir out_precursor_fit && +#end if +#if "out_fragment_fit_FLAG" in str($OPTIONAL_OUTPUTS).split(',') + mkdir out_fragment_fit && #end if -#if $rep_param_precursor_columns: --precursor_columns - #for token in $rep_param_precursor_columns: - #if " " in str(token): - "$token.param_precursor_columns" - #else - $token.param_precursor_columns - #end if - #end for +## Main program call + +set -o pipefail && +@EXECUTABLE@ -write_ctd ./ && +python3 '$__tool_directory__/fill_ctd.py' '@EXECUTABLE@.ctd' '$args_json' '$hardcoded_json' && +@EXECUTABLE@ -ini @EXECUTABLE@.ctd +-in +${' '.join(["'in/%s.%s'"%(re.sub('[^\w\-_]', '_', _.element_identifier), $gxy2omsext(_.ext)) for _ in $in if _])} +-id_in +${' '.join(["'id_in/%s.%s'"%(re.sub('[^\w\-_]', '_', _.element_identifier), $gxy2omsext(_.ext)) for _ in $id_in if _])} +#if "out_precursor_FLAG" in str($OPTIONAL_OUTPUTS).split(',') + -out_precursor + 'out_precursor/output.${gxy2omsext("tabular")}' #end if -#if $param_precursor_error_ppm: - -precursor_error_ppm +#if "out_fragment_FLAG" in str($OPTIONAL_OUTPUTS).split(',') + -out_fragment + 'out_fragment/output.${gxy2omsext("tabular")}' #end if -#if $param_fragment_out: - -fragment_out $param_fragment_out +#if "out_precursor_fit_FLAG" in str($OPTIONAL_OUTPUTS).split(',') + -out_precursor_fit + 'out_precursor_fit/output.${gxy2omsext("tabular")}' +#end if +#if "out_fragment_fit_FLAG" in str($OPTIONAL_OUTPUTS).split(',') + -out_fragment_fit + 'out_fragment_fit/output.${gxy2omsext("tabular")}' +#end if +#if len(str($OPTIONAL_OUTPUTS).split(',')) == 0 + | tee '$stdout' #end if -#if $rep_param_fragment_columns: --fragment_columns - #for token in $rep_param_fragment_columns: - #if " " in str(token): - "$token.param_fragment_columns" - #else - $token.param_fragment_columns - #end if - #end for +## Postprocessing +#if "out_precursor_FLAG" in str($OPTIONAL_OUTPUTS).split(',') + && mv 'out_precursor/output.${gxy2omsext("tabular")}' '$out_precursor' #end if -#if $param_fragment_error_ppm: - -fragment_error_ppm +#if "out_fragment_FLAG" in str($OPTIONAL_OUTPUTS).split(',') + && mv 'out_fragment/output.${gxy2omsext("tabular")}' '$out_fragment' #end if -#if $param_fragment_mass_tolerance: - -fragment_mass_tolerance $param_fragment_mass_tolerance +#if "out_precursor_fit_FLAG" in str($OPTIONAL_OUTPUTS).split(',') + && mv 'out_precursor_fit/output.${gxy2omsext("tabular")}' '$out_precursor_fit' #end if -#if $param_separator: - -separator "$param_separator" -#end if -#if $adv_opts.adv_opts_selector=='advanced': - #if $adv_opts.param_number_of_bins: - -number_of_bins $adv_opts.param_number_of_bins +#if "out_fragment_fit_FLAG" in str($OPTIONAL_OUTPUTS).split(',') + && mv 'out_fragment_fit/output.${gxy2omsext("tabular")}' '$out_fragment_fit' #end if - #if $adv_opts.param_generate_gnuplot_scripts: - -generate_gnuplot_scripts -#end if - #if $adv_opts.param_force: - -force -#end if -#end if -]]></command> +#if "ctd_out_FLAG" in $OPTIONAL_OUTPUTS + && mv '@EXECUTABLE@.ctd' '$ctd_out' +#end if]]></command> + <configfiles> + <inputs name="args_json" data_style="paths"/> + <configfile name="hardcoded_json"><![CDATA[{"log": "log.txt", "threads": "\${GALAXY_SLOTS:-1}", "no_progress": true}]]></configfile> + </configfiles> <inputs> - <param name="param_in" type="data" format="mzml" multiple="true" optional="False" size="30" label="Input mzML file list, containing the spectra" help="(-in) "> - <sanitizer> - <valid initial="string.printable"> - <remove value="'"/> - <remove value="""/> - </valid> - </sanitizer> - </param> - <param name="param_id_in" type="data" format="idxml" multiple="true" optional="False" size="30" label="Input idXML file list, containing the identifications" help="(-id_in) "> - <sanitizer> - <valid initial="string.printable"> - <remove value="'"/> - <remove value="""/> - </valid> - </sanitizer> - </param> - <repeat name="rep_param_precursor_columns" min="0" max="1" title="param_precursor_columns"> - <param name="param_precursor_columns" display="radio" type="select" optional="True" value="MassDifference" label="Columns which will be written to the output file" help="(-precursor_columns) "> - <option value="MassDifference">MassDifference</option> + <param name="in" argument="-in" type="data" format="mzml" multiple="true" optional="false" label="Input mzML file list, containing the spectra" help=" select mzml data sets(s)"/> + <param name="id_in" argument="-id_in" type="data" format="idxml" multiple="true" optional="false" label="Input idXML file list, containing the identifications" help=" select idxml data sets(s)"/> + <param name="precursor_error_ppm" argument="-precursor_error_ppm" type="boolean" truevalue="true" falsevalue="false" checked="false" label="If this flag is used, the precursor mass tolerances are estimated in ppm instead of Da" help=""/> + <param name="fragment_error_ppm" argument="-fragment_error_ppm" type="boolean" truevalue="true" falsevalue="false" checked="false" label="If this flag is used, the fragment mass tolerances are estimated in ppm instead of Da" help=""/> + <param name="fragment_mass_tolerance" argument="-fragment_mass_tolerance" type="float" optional="true" value="0.5" label="Maximal fragment mass tolerance which is allowed for MS/MS spectra, used for the calculation of matching ions" help=""/> + <expand macro="adv_opts_macro"> + <param name="number_of_bins" argument="-number_of_bins" type="integer" optional="true" min="10" value="100" label="Number of bins that should be used to calculate the histograms for the fitting" help=""/> + <param name="force" argument="-force" type="boolean" truevalue="true" falsevalue="false" checked="false" label="Overwrite tool specific checks" help=""/> + <param name="test" argument="-test" type="hidden" optional="true" value="False" label="Enables the test mode (needed for internal use only)" help=""> + <expand macro="list_string_san"/> </param> - </repeat> - <param name="param_precursor_error_ppm" display="radio" type="boolean" truevalue="-precursor_error_ppm" falsevalue="" checked="false" optional="True" label="If this flag is used, the precursor mass tolerances are estimated in ppm instead of Da" help="(-precursor_error_ppm) "/> - <repeat name="rep_param_fragment_columns" min="0" max="1" title="param_fragment_columns"> - <param name="param_fragment_columns" display="radio" type="select" optional="True" value="MassDifference" label="Columns which will be written to the output file" help="(-fragment_columns) "> - <option value="MassDifference">MassDifference</option> - </param> - </repeat> - <param name="param_fragment_error_ppm" display="radio" type="boolean" truevalue="-fragment_error_ppm" falsevalue="" checked="false" optional="True" label="If this flag is used, the fragment mass tolerances are estimated in ppm instead of Da" help="(-fragment_error_ppm) "/> - <param name="param_fragment_mass_tolerance" type="float" value="0.5" label="Maximal fragment mass tolerance which is allowed for MS/MS spectra, used for the calculation of matching ions" help="(-fragment_mass_tolerance) "/> - <param name="param_separator" type="text" size="30" value=" " label="character which should be used to separate the columns in the output files" help="(-separator) "> - <sanitizer> - <valid initial="string.printable"> - <remove value="'"/> - <remove value="""/> - </valid> - </sanitizer> + </expand> + <param name="OPTIONAL_OUTPUTS" type="select" multiple="true" label="Optional outputs" optional="false"> + <option value="out_precursor_FLAG">out_precursor (Enables the test mode (needed for internal use only))</option> + <option value="out_fragment_FLAG">out_fragment (Enables the test mode (needed for internal use only))</option> + <option value="out_precursor_fit_FLAG">out_precursor_fit (Enables the test mode (needed for internal use only))</option> + <option value="out_fragment_fit_FLAG">out_fragment_fit (Enables the test mode (needed for internal use only))</option> + <option value="ctd_out_FLAG">Output used ctd (ini) configuration file</option> </param> - <expand macro="advanced_options"> - <param name="param_number_of_bins" type="integer" min="10" optional="True" value="100" label="Number of bins that should be used to calculate the histograms for the fitting" help="(-number_of_bins) "/> - <param name="param_generate_gnuplot_scripts" display="radio" type="boolean" truevalue="-generate_gnuplot_scripts" falsevalue="" checked="false" optional="True" label="If this option is set to true, the distributions and the fits are used to generate a gnuplot script, that can be used to generate plots" help="(-generate_gnuplot_scripts) The options 'precursor_out' and 'fragment_out' must be set to take this effect"/> - <param name="param_force" display="radio" type="boolean" truevalue="-force" falsevalue="" checked="false" optional="True" label="Overwrite tool specific checks" help="(-force) "/> - </expand> </inputs> <outputs> - <data name="param_precursor_out" format="tabular"/> - <data name="param_fragment_out" format="tabular"/> + <data name="out_precursor" label="${tool.name} on ${on_string}: out_precursor" format="tabular"> + <filter>OPTIONAL_OUTPUTS is not None and "out_precursor_FLAG" in OPTIONAL_OUTPUTS</filter> + </data> + <data name="out_fragment" label="${tool.name} on ${on_string}: out_fragment" format="tabular"> + <filter>OPTIONAL_OUTPUTS is not None and "out_fragment_FLAG" in OPTIONAL_OUTPUTS</filter> + </data> + <data name="out_precursor_fit" label="${tool.name} on ${on_string}: out_precursor_fit" format="tabular"> + <filter>OPTIONAL_OUTPUTS is not None and "out_precursor_fit_FLAG" in OPTIONAL_OUTPUTS</filter> + </data> + <data name="out_fragment_fit" label="${tool.name} on ${on_string}: out_fragment_fit" format="tabular"> + <filter>OPTIONAL_OUTPUTS is not None and "out_fragment_fit_FLAG" in OPTIONAL_OUTPUTS</filter> + </data> + <data name="stdout" format="txt" label="${tool.name} on ${on_string}: stdout"> + <filter>OPTIONAL_OUTPUTS is None</filter> + </data> + <data name="ctd_out" format="xml" label="${tool.name} on ${on_string}: ctd"> + <filter>OPTIONAL_OUTPUTS is not None and "ctd_out_FLAG" in OPTIONAL_OUTPUTS</filter> + </data> </outputs> - <help>Calculates a distribution of the mass error from given mass spectra and IDs. + <tests> + <expand macro="autotest_IDMassAccuracy"/> + <expand macro="manutest_IDMassAccuracy"/> + </tests> + <help><![CDATA[Calculates a distribution of the mass error from given mass spectra and IDs. -For more information, visit https://abibuilder.informatik.uni-tuebingen.de/archive/openms/Documentation/release/2.3.0/html/UTILS_IDMassAccuracy.html</help> +For more information, visit http://www.openms.de/documentation/UTILS_IDMassAccuracy.html]]></help> + <expand macro="references"/> </tool>