diff FalseDiscoveryRate.xml @ 11:100359fb8e7c draft

"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit 020906fb54bde7fc143c356f41975c378a741315"
author galaxyp
date Wed, 09 Sep 2020 12:56:39 +0000
parents 7cc2a2687bff
children 469690558892
line wrap: on
line diff
--- a/FalseDiscoveryRate.xml	Fri May 17 10:01:38 2019 -0400
+++ b/FalseDiscoveryRate.xml	Wed Sep 09 12:56:39 2020 +0000
@@ -1,92 +1,90 @@
 <?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: [ID Processing]-->
-<tool id="FalseDiscoveryRate" name="FalseDiscoveryRate" version="2.3.0">
+<tool id="FalseDiscoveryRate" name="FalseDiscoveryRate" version="@TOOL_VERSION@+galaxy@GALAXY_VERSION@" profile="20.05">
   <description>Estimates the false discovery rate on peptide and protein level using decoy searches.</description>
   <macros>
     <token name="@EXECUTABLE@">FalseDiscoveryRate</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[FalseDiscoveryRate
+  <command detect_errors="exit_code"><![CDATA[@QUOTE_FOO@
+@EXT_FOO@
+#import re
+
+## Preprocessing
+mkdir in &&
+ln -s '$in' 'in/${re.sub("[^\w\-_]", "_", $in.element_identifier)}.$gxy2omsext($in.ext)' &&
+mkdir out &&
+
+## 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
+'in/${re.sub("[^\w\-_]", "_", $in.element_identifier)}.$gxy2omsext($in.ext)'
+-out
+'out/output.${gxy2omsext("idxml")}'
 
-#if $param_in:
-  -in $param_in
-#end if
-#if $param_out:
-  -out $param_out
-#end if
-#if $param_PSM:
-  -PSM
-  #if " " in str($param_PSM):
-    "$param_PSM"
-  #else
-    $param_PSM
-  #end if
-#end if
-#if $param_protein:
-  -protein
-  #if " " in str($param_protein):
-    "$param_protein"
-  #else
-    $param_protein
-  #end if
-#end if
-#if $param_FDR_PSM:
-  -FDR:PSM $param_FDR_PSM
-#end if
-#if $param_FDR_protein:
-  -FDR:protein $param_FDR_protein
-#end if
-#if $param_algorithm_no_qvalues:
-  -algorithm:no_qvalues
-#end if
-#if $param_algorithm_use_all_hits:
-  -algorithm:use_all_hits
-#end if
-#if $param_algorithm_split_charge_variants:
-  -algorithm:split_charge_variants
-#end if
-#if $param_algorithm_treat_runs_separately:
-  -algorithm:treat_runs_separately
-#end if
-#if $param_algorithm_add_decoy_peptides:
-  -algorithm:add_decoy_peptides
-#end if
-#if $adv_opts.adv_opts_selector=='advanced':
-    #if $adv_opts.param_force:
-  -force
-#end if
-#end if
-]]></command>
+## Postprocessing
+&& mv 'out/output.${gxy2omsext("idxml")}' '$out'
+#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="idxml" optional="False" label="Identifications from searching a target-decoy database" help="(-in) "/>
-    <param name="param_PSM" display="radio" type="select" optional="False" value="true" label="Perform FDR calculation on PSM level" help="(-PSM) ">
-      <option value="true" selected="true">true</option>
-      <option value="false">false</option>
-    </param>
-    <param name="param_protein" display="radio" type="select" optional="False" value="true" label="Perform FDR calculation on protein level" help="(-protein) ">
-      <option value="true" selected="true">true</option>
-      <option value="false">false</option>
+    <param name="in" argument="-in" type="data" format="idxml" optional="false" label="Identifications from searching a target-decoy database" help=" select idxml data sets(s)"/>
+    <param name="PSM" argument="-PSM" type="boolean" truevalue="true" falsevalue="false" checked="true" label="Perform FDR calculation on PSM level" help=""/>
+    <param name="protein" argument="-protein" type="boolean" truevalue="true" falsevalue="false" checked="true" label="Perform FDR calculation on protein level" help=""/>
+    <section name="FDR" title="FDR control" help="" expanded="false">
+      <param name="PSM" argument="-FDR:PSM" type="float" optional="true" min="0.0" max="1.0" value="1.0" label="Filter PSMs based on q-value" help="(e.g., 0.05 = 5% FDR, disabled for 1)"/>
+      <param name="protein" argument="-FDR:protein" type="float" optional="true" min="0.0" max="1.0" value="1.0" label="Filter proteins based on q-value" help="(e.g., 0.05 = 5% FDR, disabled for 1)"/>
+      <section name="cleanup" title="Cleanup references after FDR control" help="" expanded="false">
+        <param name="remove_proteins_without_psms" argument="-FDR:cleanup:remove_proteins_without_psms" type="boolean" truevalue="true" falsevalue="false" checked="true" label="Remove proteins without PSMs (due to being decoy or below PSM FDR threshold)" help=""/>
+        <param name="remove_psms_without_proteins" argument="-FDR:cleanup:remove_psms_without_proteins" type="boolean" truevalue="true" falsevalue="false" checked="true" label="Remove PSMs without proteins (due to being decoy or below protein FDR threshold)" help=""/>
+        <param name="remove_spectra_without_psms" argument="-FDR:cleanup:remove_spectra_without_psms" type="boolean" truevalue="true" falsevalue="false" checked="true" label="Remove spectra without PSMs (due to being decoy or below protein FDR threshold)" help="Caution: if remove_psms_without_proteins is false, protein level filtering does not propagate"/>
+      </section>
+    </section>
+    <section name="algorithm" title="Parameter section for the FDR calculation algorithm" help="" expanded="false">
+      <param name="no_qvalues" argument="-algorithm:no_qvalues" type="boolean" truevalue="true" falsevalue="false" checked="false" label="If 'true' strict FDRs will be calculated instead of q-values (the default)" help=""/>
+      <param name="use_all_hits" argument="-algorithm:use_all_hits" type="boolean" truevalue="true" falsevalue="false" checked="false" label="If 'true' not only the first hit, but all are used (peptides only)" help=""/>
+      <param name="split_charge_variants" argument="-algorithm:split_charge_variants" type="boolean" truevalue="true" falsevalue="false" checked="false" label="If 'true' charge variants are treated separately (for peptides of combined target/decoy searches only)" help=""/>
+      <param name="treat_runs_separately" argument="-algorithm:treat_runs_separately" type="boolean" truevalue="true" falsevalue="false" checked="false" label="If 'true' different search runs are treated separately (for peptides of combined target/decoy searches only)" help=""/>
+      <param name="add_decoy_peptides" argument="-algorithm:add_decoy_peptides" type="boolean" truevalue="true" falsevalue="false" checked="false" label="If 'true' decoy peptides will be written to output file, too" help="The q-value is set to the closest target score"/>
+      <param name="add_decoy_proteins" argument="-algorithm:add_decoy_proteins" type="boolean" truevalue="true" falsevalue="false" checked="false" label="If 'true' decoy proteins will be written to output file, too" help="The q-value is set to the closest target score"/>
+      <param name="conservative" argument="-algorithm:conservative" type="boolean" truevalue="true" falsevalue="false" checked="true" label="If 'true' (D+1)/T instead of (D+1)/(T+D) is used as a formula" help=""/>
+    </section>
+    <expand macro="adv_opts_macro">
+      <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>
+    </expand>
+    <param name="OPTIONAL_OUTPUTS" type="select" multiple="true" label="Optional outputs" optional="true">
+      <option value="ctd_out_FLAG">Output used ctd (ini) configuration file</option>
     </param>
-    <param name="param_FDR_PSM" type="float" min="0.0" max="1.0" optional="True" value="1.0" label="Filter PSMs based on q-value (" help="(-PSM) e.g., 0.05 = 5% FDR, disabled for 1)"/>
-    <param name="param_FDR_protein" type="float" min="0.0" max="1.0" optional="True" value="1.0" label="Filter proteins based on q-value (" help="(-protein) e.g., 0.05 = 5% FDR, disabled for 1)"/>
-    <param name="param_algorithm_no_qvalues" display="radio" type="boolean" truevalue="-algorithm:no_qvalues" falsevalue="" checked="false" optional="True" label="If 'true' strict FDRs will be calculated instead of q-values (the default)" help="(-no_qvalues) "/>
-    <param name="param_algorithm_use_all_hits" display="radio" type="boolean" truevalue="-algorithm:use_all_hits" falsevalue="" checked="false" optional="True" label="If 'true' not only the first hit, but all are used (peptides only)" help="(-use_all_hits) "/>
-    <param name="param_algorithm_split_charge_variants" display="radio" type="boolean" truevalue="-algorithm:split_charge_variants" falsevalue="" checked="false" optional="True" label="If 'true' charge variants are treated separately (for peptides of combined target/decoy searches only)" help="(-split_charge_variants) "/>
-    <param name="param_algorithm_treat_runs_separately" display="radio" type="boolean" truevalue="-algorithm:treat_runs_separately" falsevalue="" checked="false" optional="True" label="If 'true' different search runs are treated separately (for peptides of combined target/decoy searches only)" help="(-treat_runs_separately) "/>
-    <param name="param_algorithm_add_decoy_peptides" display="radio" type="boolean" truevalue="-algorithm:add_decoy_peptides" falsevalue="" checked="false" optional="True" label="If 'true' decoy peptides will be written to output file, too" help="(-add_decoy_peptides) The q-value is set to the closest target score"/>
-    <expand macro="advanced_options">
-      <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_out" format="idxml"/>
+    <data name="out" label="${tool.name} on ${on_string}: out" format="idxml"/>
+    <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>Estimates the false discovery rate on peptide and protein level using decoy searches.
+  <tests>
+    <expand macro="autotest_FalseDiscoveryRate"/>
+    <expand macro="manutest_FalseDiscoveryRate"/>
+  </tests>
+  <help><![CDATA[Estimates the false discovery rate on peptide and protein level using decoy searches.
 
 
-For more information, visit https://abibuilder.informatik.uni-tuebingen.de/archive/openms/Documentation/release/2.3.0/html/TOPP_FalseDiscoveryRate.html</help>
+For more information, visit http://www.openms.de/documentation/TOPP_FalseDiscoveryRate.html]]></help>
+  <expand macro="references"/>
 </tool>