Mercurial > repos > tomnl > mspurity_dimspredictpuritysingle
diff dimsPredictPuritySingle.xml @ 14:1389e565f95e draft default tip
planemo upload for repository https://github.com/computational-metabolomics/mspurity-galaxy commit cb903cd93f9378cfb5eeb68512a54178dcea7bbc
| author | tomnl |
|---|---|
| date | Wed, 27 Nov 2019 12:37:27 +0000 |
| parents | 1ce857d74106 |
| children |
line wrap: on
line diff
--- a/dimsPredictPuritySingle.xml Fri Sep 27 09:27:10 2019 -0400 +++ b/dimsPredictPuritySingle.xml Wed Nov 27 12:37:27 2019 +0000 @@ -1,25 +1,33 @@ <tool id="mspurity_dimspredictpuritysingle" name="msPurity.dimsPredictPuritySingle" version="@TOOL_VERSION@+galaxy@GALAXY_TOOL_VERSION@"> - <description>Calculate the anticipated precursor ion purity from a DIMS dataset. - </description> + <description>Calculate the anticipated precursor ion purity from a DIMS dataset.</description> <macros> <import>macros.xml</import> </macros> <expand macro="requirements" /> + <command detect_errors="exit_code"><![CDATA[ + Rscript '$__tool_directory__/dimsPredictPuritySingle.R' + #if $mzML_data.format == 'mzML_file' + --mzML_file '$mzML_data.source' + #elif $mzML_data.format == 'library' + --mzML_file '$__app__.config.user_library_import_dir/$__user_email__/$mzML_data.source' + #elif $mzML_data.format == 'mzML_data_collection' + --mzML_files=' + #for $i in $mzML_data.source + $i, + #end for + ' + --galaxy_names=' + #for $i in $mzML_data.source + $i.name, + #end for + ' + --mzML_filename=' $mzML_data.mzML_filename' - <stdio> - <exit_code range="1:" /> - </stdio> - <command interpreter="Rscript"><![CDATA[ - dimsPredictPuritySingle.R - #if $mzML_data.format == "mzML_file" - --mzML_file $mzML_data.source - #elif $mzML_data.format == "library" - --mzML_file $__app__.config.user_library_import_dir/$__user_email__/$mzML_data.source #end if - --peaks_file=$peaks_file - --out_dir=. - --minOffset=$minoffset - --maxOffset=$maxoffset + --peaks_file='$peaks_file' + --out_dir='.' + --minoffset=$minoffset + --maxoffset=$maxoffset --ppm=$ppm --iwNorm=$iw_norm --ilim=$ilim @@ -31,57 +39,58 @@ #end if #if $dimspy_usage.usage == "dimspy" --dimspy - --file_num_dimspy $dimspy_usage.file_num + --file_num_dimspy $dimspy_usage.file_num_dimspy #end if #if $isotopes.isotopes == "exclude_default": --exclude_isotopes #elif $isotopes.isotopes == "user" --exclude_isotopes - --isotope_matrix = $isotopes.im + --isotope_matrix = '$isotopes.im' #end if ]]></command> <inputs> - <param type="data" name="peaks_file" format="tsv, tabular" + <param argument="--peaks_file" type="data" format="tsv, tabular" help="tsv or tabular file with one column containing the mz values (column header should be either mz)"/> <conditional name="mzML_data"> <param name="format" type="select" label="Choose the source for the dataset" > - <option value="mzML_file" selected="true">.mzML files to check purity from</option> + <option value="mzML_file" selected="true">A single .mzML files to check purity from</option> <option value="library">Library directory name (to be used with dimspy workflows) or path to to an individual .mzML file</option> + <option value="mzML_data_collection" selected="true">A data collection of .mzML files</option> </param> <when value="mzML_file"> - <param name="source" type="data" format="mzml" label="Single *.mzML" argument="--mzML_file" > - <validator type="empty_field" /> - </param> - </when> - <when value="library"> - <param name="source" type="text" - size="40" label="Library directory containing *.mzml files - or path to an individual *.mzML" - argument="--mzML_file"> + <param argument="--mzML_file" name="source" type="data" format="mzml" label="Single *.mzML" > <validator type="empty_field" /> </param> </when> + <when value="mzML_data_collection"> + <param argument="--mzML_files" name="source" type="data_collection" + label="Data collection containing *.mzml files" > + <validator type="empty_field" /> + </param> + <param argument="--mzML_filename" type="text" label="Name of file to to calculate purity from" help=""/> + </when> + + <when value="library"> + <param argument="--mzML_file" name="source" type="text" + size="40" label="Library directory containing *.mzml files (dimspy input only) + or path to an individual .mzML file"> + <validator type="empty_field" /> + </param> + </when> + </conditional> + <expand macro="general_params" /> <expand macro="offsets" /> - <expand macro="general_params" /> - - - <param name="ppm" type="float" label="ppm" value="10" - help="ppm tolerance to compare between mz values"/> - <param name="minoffset" type="float" label="minoffset" value="0.5" - help="Offset to the 'left' for the precursor range e.g. if precursor of interest is - 100.0 then the range would be from 999.5 to 100.0"/> - - <param name="remove_NAs" type="boolean" label="Remove rows where mz value is NA or NaN?" help=""/> - - <param name="sim" type="boolean" label="SIM-Stitch experiment?" help=""/> - + <param argument="--ppm" type="float" label="ppm" min="0" value="10" + help="ppm tolerance to compare between mz values"/> + <param argument="--remove_NAs" type="boolean" label="Remove rows where mz value is NA or NaN?" help=""/> + <param argument="--sim" type="boolean" label="SIM-Stitch experiment?" help=""/> <conditional name="dimspy_usage"> <param name="usage" type="select" label="dimspy peak matrix text file usage?"> <option value="no_dimspy" selected="true">dimspy not used to prepare the mz text file</option> @@ -90,7 +99,7 @@ <when value="no_dimspy"> </when> <when value="dimspy"> - <param name="file_num" type="integer" label="File number" value="1" + <param argument="--file_num_dimspy" type="integer" label="File number" min="0" value="1" help="Choose the file number from the dimspy matrix to use to calculate the precursor ion purity metric (order based on column order). This file will then be looked for in the library folder to calculate the metric. @@ -109,6 +118,7 @@ <param name="mzML_data|source" value="dimsPredictPuritySingle_full_scan.mzML" /> <param name="remove_NAs" value="True" /> <param name="dimspy_usage|usage" value="dimspy" /> + <param name="dimspy_usage|file_num_dimspy" value="1" /> <param name="peaks_file" value="dimsPredictPuritySingle_input_dimspy_peakmatrix.tsv" /> <output name="dimsPredictPuritySingle_output" value="dimsPredictPuritySingle_output.tsv" /> </test>
