diff OpenSwathDecoyGenerator.xml @ 14:e833a89f25c8 draft default tip

planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit 5c080b1e2b99f1c88f4557e9fec8c45c9d23b906
author galaxyp
date Fri, 14 Jun 2024 21:45:00 +0000
parents 496cf619e311
children
line wrap: on
line diff
--- a/OpenSwathDecoyGenerator.xml	Thu Dec 01 19:18:22 2022 +0000
+++ b/OpenSwathDecoyGenerator.xml	Fri Jun 14 21:45:00 2024 +0000
@@ -1,6 +1,5 @@
-<?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: [Targeted Experiments]-->
+<!--Proposed Tool Section: [Targeted Experiments and OpenSWATH]-->
 <tool id="OpenSwathDecoyGenerator" name="OpenSwathDecoyGenerator" version="@TOOL_VERSION@+galaxy@VERSION_SUFFIX@" profile="21.05">
   <description>Generates decoys according to different models for a specific TraML</description>
   <macros>
@@ -15,7 +14,7 @@
 
 ## Preprocessing
 mkdir in &&
-ln -s '$in' 'in/${re.sub("[^\w\-_]", "_", $in.element_identifier)}.$gxy2omsext($in.ext)' &&
+cp '$in' 'in/${re.sub("[^\w\-_]", "_", $in.element_identifier)}.$gxy2omsext($in.ext)' &&
 mkdir out &&
 
 ## Main program call
@@ -39,43 +38,44 @@
     <configfile name="hardcoded_json"><![CDATA[{"log": "log.txt", "threads": "\${GALAXY_SLOTS:-1}", "no_progress": true}]]></configfile>
   </configfiles>
   <inputs>
-    <param argument="-in" type="data" format="mrm,pqp,tabular,traml" optional="false" label="Input file" help=" select mrm,pqp,tabular,traml data sets(s)"/>
-    <param argument="-out_type" display="radio" type="select" optional="false" label="Output file type -- default: determined from file extension or content" help="">
+    <param argument="-in" type="data" format="mrm,pqp,tabular,traml" label="Input file" help=" select mrm,pqp,tabular,traml data sets(s)"/>
+    <param argument="-out_type" type="select" label="Output file type -- default: determined from file extension or content" help="">
       <option value="TraML">traml</option>
       <option value="pqp">pqp</option>
       <option value="tsv">tabular (tsv)</option>
+      <validator type="expression" message="A value needs to be selected">value != "select a value"</validator>
       <expand macro="list_string_san" name="out_type"/>
     </param>
-    <param argument="-method" type="select" optional="true" label="Decoy generation method" help="">
+    <param argument="-method" type="select" label="Decoy generation method" help="">
       <option value="shuffle" selected="true">shuffle</option>
       <option value="pseudo-reverse">pseudo-reverse</option>
       <option value="reverse">reverse</option>
       <option value="shift">shift</option>
       <expand macro="list_string_san" name="method"/>
     </param>
-    <param argument="-decoy_tag" type="text" optional="true" value="DECOY_" label="decoy tag" help="">
+    <param argument="-decoy_tag" type="text" value="DECOY_" label="decoy tag" help="">
       <expand macro="list_string_san" name="decoy_tag"/>
     </param>
     <param argument="-switchKR" type="boolean" truevalue="true" falsevalue="false" checked="true" label="Whether to switch terminal K and R (to achieve different precursor mass)" help=""/>
     <expand macro="adv_opts_macro">
-      <param argument="-min_decoy_fraction" type="float" optional="true" value="0.8" label="Minimum fraction of decoy / target peptides and proteins" help=""/>
-      <param argument="-aim_decoy_fraction" type="float" optional="true" value="1.0" label="Number of decoys the algorithm should generate (if unequal to 1, the algorithm will randomly select N peptides for decoy generation)" help=""/>
-      <param argument="-shuffle_max_attempts" type="integer" optional="true" value="30" label="shuffle: maximum attempts to lower the amino acid sequence identity between target and decoy for the shuffle algorithm" help=""/>
-      <param argument="-shuffle_sequence_identity_threshold" type="float" optional="true" value="0.5" label="shuffle: target-decoy amino acid sequence identity threshold for the shuffle algorithm" help=""/>
-      <param argument="-shift_precursor_mz_shift" type="float" optional="true" value="0.0" label="shift: precursor ion MZ shift in Thomson for shift decoy method" help=""/>
-      <param argument="-shift_product_mz_shift" type="float" optional="true" value="20.0" label="shift: fragment ion MZ shift in Thomson for shift decoy method" help=""/>
-      <param argument="-product_mz_threshold" type="float" optional="true" value="0.025" label="MZ threshold in Thomson for fragment ion annotation" help=""/>
-      <param argument="-allowed_fragment_types" type="text" optional="true" value="b,y" label="allowed fragment types" help="">
+      <param argument="-min_decoy_fraction" type="float" value="0.8" label="Minimum fraction of decoy / target peptides and proteins" help=""/>
+      <param argument="-aim_decoy_fraction" type="float" value="1.0" label="Number of decoys the algorithm should generate (if unequal to 1, the algorithm will randomly select N peptides for decoy generation)" help=""/>
+      <param argument="-shuffle_max_attempts" type="integer" value="30" label="shuffle: maximum attempts to lower the amino acid sequence identity between target and decoy for the shuffle algorithm" help=""/>
+      <param argument="-shuffle_sequence_identity_threshold" type="float" value="0.5" label="shuffle: target-decoy amino acid sequence identity threshold for the shuffle algorithm" help=""/>
+      <param argument="-shift_precursor_mz_shift" type="float" value="0.0" label="shift: precursor ion MZ shift in Thomson for shift decoy method" help=""/>
+      <param argument="-shift_product_mz_shift" type="float" value="20.0" label="shift: fragment ion MZ shift in Thomson for shift decoy method" help=""/>
+      <param argument="-product_mz_threshold" type="float" value="0.025" label="MZ threshold in Thomson for fragment ion annotation" help=""/>
+      <param argument="-allowed_fragment_types" type="text" value="b,y" label="allowed fragment types" help="">
         <expand macro="list_string_san" name="allowed_fragment_types"/>
       </param>
-      <param argument="-allowed_fragment_charges" type="text" optional="true" value="1,2,3,4" label="allowed fragment charge states" help="">
+      <param argument="-allowed_fragment_charges" type="text" value="1,2,3,4" label="allowed fragment charge states" help="">
         <expand macro="list_string_san" name="allowed_fragment_charges"/>
       </param>
       <param argument="-enable_detection_specific_losses" type="boolean" truevalue="true" falsevalue="false" checked="false" label="set this flag if specific neutral losses for detection fragment ions should be allowed" help=""/>
       <param argument="-enable_detection_unspecific_losses" type="boolean" truevalue="true" falsevalue="false" checked="false" label="set this flag if unspecific neutral losses (H2O1, H3N1, C1H2N2, C1H2N1O1) for detection fragment ions should be allowed" help=""/>
       <param argument="-separate" type="boolean" truevalue="true" falsevalue="false" checked="false" label="set this flag if decoys should not be appended to targets" help=""/>
       <param argument="-force" type="boolean" truevalue="true" falsevalue="false" checked="false" label="Overrides tool-specific checks" help=""/>
-      <param argument="-test" type="hidden" optional="true" value="False" label="Enables the test mode (needed for internal use only)" help="">
+      <param argument="-test" type="hidden" value="False" label="Enables the test mode (needed for internal use only)" help="" optional="true">
         <expand macro="list_string_san" name="test"/>
       </param>
     </expand>
@@ -94,7 +94,8 @@
       <filter>OPTIONAL_OUTPUTS is not None and "ctd_out_FLAG" in OPTIONAL_OUTPUTS</filter>
     </data>
   </outputs>
-  <tests><!-- TOPP_OpenSwathDecoyGenerator_test_1 -->
+  <tests>
+    <!-- TOPP_OpenSwathDecoyGenerator_test_1 -->
     <test expect_num_outputs="2">
       <section name="adv_opts">
         <param name="min_decoy_fraction" value="0.8"/>
@@ -113,7 +114,7 @@
         <param name="test" value="true"/>
       </section>
       <param name="in" value="OpenSwathDecoyGenerator_input.TraML"/>
-      <output name="out" file="OpenSwathDecoyGenerator_output.TraML" compare="sim_size" delta_frac="0.7" ftype="traml"/>
+      <output name="out" value="OpenSwathDecoyGenerator_output.TraML" compare="sim_size" delta_frac="0.7" ftype="traml"/>
       <param name="out_type" value="TraML"/>
       <param name="method" value="pseudo-reverse"/>
       <param name="decoy_tag" value="DECOY_"/>
@@ -124,6 +125,9 @@
           <is_valid_xml/>
         </assert_contents>
       </output>
+      <assert_stdout>
+        <has_text_matching expression="@EXECUTABLE@ took .* \(wall\), .* \(CPU\), .* \(system\), .* \(user\)(; Peak Memory Usage: 32 MB)?."/>
+      </assert_stdout>
     </test>
     <!-- TOPP_OpenSwathDecoyGenerator_test_2 -->
     <test expect_num_outputs="2">
@@ -144,7 +148,7 @@
         <param name="test" value="true"/>
       </section>
       <param name="in" value="OpenSwathDecoyGenerator_input_2.TraML"/>
-      <output name="out" file="OpenSwathDecoyGenerator_output_2.TraML" compare="sim_size" delta_frac="0.7" ftype="traml"/>
+      <output name="out" value="OpenSwathDecoyGenerator_output_2.TraML" compare="sim_size" delta_frac="0.7" ftype="traml"/>
       <param name="out_type" value="TraML"/>
       <param name="method" value="pseudo-reverse"/>
       <param name="decoy_tag" value="DECOY_"/>
@@ -155,6 +159,9 @@
           <is_valid_xml/>
         </assert_contents>
       </output>
+      <assert_stdout>
+        <has_text_matching expression="@EXECUTABLE@ took .* \(wall\), .* \(CPU\), .* \(system\), .* \(user\)(; Peak Memory Usage: 32 MB)?."/>
+      </assert_stdout>
     </test>
     <!-- TOPP_OpenSwathDecoyGenerator_test_3 -->
     <test expect_num_outputs="2">
@@ -175,7 +182,7 @@
         <param name="test" value="true"/>
       </section>
       <param name="in" value="OpenSwathDecoyGenerator_input_3.TraML"/>
-      <output name="out" file="OpenSwathDecoyGenerator_output_3.TraML" compare="sim_size" delta_frac="0.7" ftype="traml"/>
+      <output name="out" value="OpenSwathDecoyGenerator_output_3.TraML" compare="sim_size" delta_frac="0.7" ftype="traml"/>
       <param name="out_type" value="TraML"/>
       <param name="method" value="pseudo-reverse"/>
       <param name="decoy_tag" value="DECOY_"/>
@@ -186,6 +193,9 @@
           <is_valid_xml/>
         </assert_contents>
       </output>
+      <assert_stdout>
+        <has_text_matching expression="@EXECUTABLE@ took .* \(wall\), .* \(CPU\), .* \(system\), .* \(user\)(; Peak Memory Usage: 32 MB)?."/>
+      </assert_stdout>
     </test>
     <!-- TOPP_OpenSwathDecoyGenerator_test_4 -->
     <test expect_num_outputs="2">
@@ -206,7 +216,7 @@
         <param name="test" value="true"/>
       </section>
       <param name="in" value="OpenSwathDecoyGenerator_input_4.tsv" ftype="tabular"/>
-      <output name="out" file="OpenSwathDecoyGenerator_output_4.TraML" compare="sim_size" delta_frac="0.7" ftype="traml"/>
+      <output name="out" value="OpenSwathDecoyGenerator_output_4.TraML" compare="sim_size" delta_frac="0.7" ftype="traml"/>
       <param name="out_type" value="TraML"/>
       <param name="method" value="pseudo-reverse"/>
       <param name="decoy_tag" value="DECOY_"/>
@@ -217,11 +227,48 @@
           <is_valid_xml/>
         </assert_contents>
       </output>
+      <assert_stdout>
+        <has_text_matching expression="@EXECUTABLE@ took .* \(wall\), .* \(CPU\), .* \(system\), .* \(user\)(; Peak Memory Usage: 32 MB)?."/>
+      </assert_stdout>
+    </test>
+    <!-- TOPP_OpenSwathDecoyGenerator_test_5 -->
+    <test expect_num_outputs="2">
+      <section name="adv_opts">
+        <param name="min_decoy_fraction" value="0.4"/>
+        <param name="aim_decoy_fraction" value="1.0"/>
+        <param name="shuffle_max_attempts" value="30"/>
+        <param name="shuffle_sequence_identity_threshold" value="0.5"/>
+        <param name="shift_precursor_mz_shift" value="0.0"/>
+        <param name="shift_product_mz_shift" value="20.0"/>
+        <param name="product_mz_threshold" value="0.025"/>
+        <param name="allowed_fragment_types" value="b,y"/>
+        <param name="allowed_fragment_charges" value="1,2,3,4"/>
+        <param name="enable_detection_specific_losses" value="false"/>
+        <param name="enable_detection_unspecific_losses" value="false"/>
+        <param name="separate" value="false"/>
+        <param name="force" value="false"/>
+        <param name="test" value="true"/>
+      </section>
+      <param name="in" value="OpenSwathDecoyGenerator_input_5.tsv" ftype="tabular"/>
+      <output name="out" value="OpenSwathDecoyGenerator_output_5.TraML" compare="sim_size" delta_frac="0.7" ftype="traml"/>
+      <param name="out_type" value="TraML"/>
+      <param name="method" value="pseudo-reverse"/>
+      <param name="decoy_tag" value="DECOY_"/>
+      <param name="switchKR" value="false"/>
+      <param name="OPTIONAL_OUTPUTS" value="ctd_out_FLAG"/>
+      <output name="ctd_out" ftype="xml">
+        <assert_contents>
+          <is_valid_xml/>
+        </assert_contents>
+      </output>
+      <assert_stdout>
+        <has_text_matching expression="@EXECUTABLE@ took .* \(wall\), .* \(CPU\), .* \(system\), .* \(user\)(; Peak Memory Usage: 32 MB)?."/>
+      </assert_stdout>
     </test>
   </tests>
   <help><![CDATA[Generates decoys according to different models for a specific TraML
 
 
-For more information, visit http://www.openms.de/doxygen/release/2.8.0/html/TOPP_OpenSwathDecoyGenerator.html]]></help>
+For more information, visit https://openms.de/doxygen/release/3.1.0/html/TOPP_OpenSwathDecoyGenerator.html]]></help>
   <expand macro="references"/>
 </tool>