changeset 9:ee79a49755da draft default tip

planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/rna_tools/mea commit 6767a5ffb02052c844e9d862c79912f998f39d8e
author rnateam
date Mon, 20 Nov 2017 05:03:35 -0500
parents e0f8bc01b84b
children
files mea.xml test-data/test_reference.txt test-data/test_structure.txt tool_dependencies.xml
diffstat 4 files changed, 103 insertions(+), 174 deletions(-) [+]
line wrap: on
line diff
--- a/mea.xml	Thu Dec 10 12:22:08 2015 -0500
+++ b/mea.xml	Mon Nov 20 05:03:35 2017 -0500
@@ -1,155 +1,125 @@
 <tool id="mea" name="MEA" version="0.6.4.1">
     <description>Predict MEA structures and compare structures of RNAs</description>
-    
     <requirements>
-	<requirement type="package" version="2.22.6" >gengetopt</requirement>
-	<requirement type="package" version="0.6.4" >mea</requirement>
+        <requirement type="package" version="0.6.4">mea</requirement>
     </requirements>
-    
-    <stdio>
-	<exit_code range=":-1"/>
-	<exit_code range="1:" />
-    </stdio>
-
     <version_command>mea --version</version_command>
-
-    <command><![CDATA[
+    <command detect_errors="aggressive"><![CDATA[
         mea
-        #if str($predict_mode.predict_selector) == "predict"
-            $predict_mode.dotplot
-        	#if str($predict_mode.mea_parameters.mea_parameters_selector) == "no_default"
+        #if str($predict_mode.predict_selector) == 'predict':
+            '$predict_mode.dotplot'
+            #if str($predict_mode.mea_parameters.mea_parameters_selector) == 'no_default'
                 --alpha $predict_mode.mea_parameters.alpha
-        	    --beta $predict_mode.mea_parameters.beta
-        	    --gamma $predict_mode.mea_parameters.gamma
-        	    --delta $predict_mode.mea_parameters.delta
-        	#end if
+                --beta $predict_mode.mea_parameters.beta
+                --gamma $predict_mode.mea_parameters.gamma
+                --delta $predict_mode.mea_parameters.delta
+            #end if
         #else
-            --structure `cat $predict_mode.structure`
+            --structure '$predict_mode.structure'
         #end if
-	#if $compare_mode.compare_selector
-            --reference `cat $compare_mode.reference`
+        #if str($compare_mode.compare_selector) == 'compare':
+            --reference '$compare_mode.reference'
             $compare_mode.slide_rule
             $compare_mode.conflict_rule
         #end if
         > $stdout
     ]]></command>
-    
     <inputs>
-	<conditional name="predict_mode">
-	    <param name="predict_selector" type="select" label="Predict MEA structure">
-		<option value="predict">Predict MEA structure</option>
-		<option value="compare">Specify structure (for comparison)</option>
-	    </param>
-	    <when value="predict">
-		<param name="dotplot" type="data" format="rna_eps" label="Dotplot"
-		       optional="false" help="Dotplot file (RNA base pair probabilities)"/>
-		<conditional name="mea_parameters">
-		    <param name="mea_parameters_selector"
-			   type="boolean"
-			   label="Use default parameters"
-			   truevalue="default"
-			   falsevalue="no_default"
-			   checked="yes"
-			   help="The default parameters assign a base pair weight
-				 of 0.5 and penalize long base pairs."
-			   />
-		    <when value="default" />
-		    <when value="no_default">
-			<param name="alpha" label="Alpha" type="float"
-			       optional="false" value="0.012"
-			       help="Slope of base pair distance penalty"/>
-			<param name="beta" label="Beta" type="float"
-			       optional="false" value="315"
-			       help="Turning point of base pair distance penalty" />
-			<param name="gamma" label="Gamma" type="float"
-			       optional="false" value="0.5"
-			       help="Base pair weight factor" />
-			<param name="delta" label="Delta" type="float"
-			       optional="false" value="0.003"
-			       help="Minimum penalty factor for base pairs" />
-		    </when>
-		</conditional>
-	    </when>
-	    <when value="compare">
-		<param name="structure" format="txt" type="data" label="Structure"
-		       optional="false"
-		       help="(Predicted) RNA secondary structure
-			     for comparison to a reference structure." />
-	    </when>
-	</conditional>
-
-	
-	<conditional name="compare_mode">
-	    <param name="compare_selector"
-		   type="boolean"
-		   label="Compare to a reference structure"
-		   optional="false"
-		   checked="false"
-		   truevalue="compare"
-		   falsevalue="dont_compare"
-		   help="Whether to compare the predicted (or specified) structure
-			 to a reference structure."
-		   />
-	    <when value="dont_compare" />
-	    <when value="compare">
-		<param name="reference"
-		       optional="false"
-		       format="txt" type="data"
-		       label="Reference"
-		       help="Reference structure in dot-bracket format"/>
-		
-		<param name="slide_rule" label="Slide Rule" type="boolean"
-		       optional="false"
- 		       checked="yes"
-		       falsevalue="--no-slide-rule" truevalue=""
-		       help="Use slide rule" />
-		<param name="conflict_rule" label="Conflict Rule" type="boolean"
-		       optional="false"
-		       checked="yes"
-		       falsevalue="--no-conflict-rule" truevalue=""
-		       help="Use onflict rule"/>
-	    </when>
-	</conditional>
+        <conditional name="predict_mode">
+            <param name="predict_selector" type="select" label="Predict MEA structure">
+                <option value="predict">Predict MEA structure</option>
+                <option value="compare">Specify structure (for comparison)</option>
+            </param>
+            <when value="predict">
+                <param name="dotplot" type="data" format="rna_eps" label="Dotplot" optional="False"
+                    help="Dotplot file (RNA base pair probabilities)"/>
+                <conditional name="mea_parameters">
+                    <param name="mea_parameters_selector" type="boolean" label="Use default parameters"
+                       truevalue="default" falsevalue="no_default" checked="True"
+                       help="The default parameters assign a base pair weight
+                            of 0.5 and penalize long base pairs." />
+                    <when value="default" />
+                    <when value="no_default">
+                    <param name="alpha" label="Alpha value" type="float"
+                            optional="False" value="0.012"
+                            help="Slope of base pair distance penalty. (--alpha)"/>
+                    <param name="beta" label="Beta value" type="float"
+                            optional="False" value="315"
+                            help="Turning point of base pair distance penalty. (--beta)" />
+                    <param name="gamma" label="Gamma value" type="float"
+                            optional="False" value="0.5"
+                            help="Base pair weight factor. (--gamma)" />
+                    <param name="delta" label="Delta value" type="float"
+                            optional="False" value="0.003"
+                            help="Minimum penalty factor for base pairs. (--delta)" />
+                    </when>
+                </conditional>
+            </when>
+            <when value="compare">
+                <param argument="--structure" type="text" label="Structure" optional="False"
+                    help="(Predicted) RNA secondary structure for comparison to a reference structure in dot-bracket format">
+                    <sanitizer>
+                        <valid>
+                            <add value="("/>
+                            <add value=")"/>
+                            <add value="."/>
+                        </valid>
+                    </sanitizer>
+                </param>
+            </when>
+        </conditional>
+        <conditional name="compare_mode">
+            <param name="compare_selector" type="select" label="Compare to a reference structure"
+                help="Whether to compare the predicted (or specified) structure to a reference structure.">
+                <option value="dont_compare">Do not compare</option>
+                <option value="compare">Compare to reference structure</option>
+            </param>
+            <when value="dont_compare" />
+            <when value="compare">
+                <param name="reference" optional="false" type="text" label="Reference"
+                       help="Reference structure in dot-bracket format">
+                   <sanitizer>
+                        <valid>
+                            <add value="("/>
+                            <add value=")"/>
+                            <add value="."/>
+                        </valid>
+                    </sanitizer>
+                </param> 
+                <param name="slide_rule" label="Slide Rule" type="boolean"
+                       optional="False" checked="True" falsevalue="--no-slide-rule" truevalue="" help="Use slide rule. (--no-slide-rule)" />
+                <param name="conflict_rule" label="Conflict Rule" type="boolean"
+                       optional="False" checked="True" falsevalue="--no-conflict-rule" truevalue="" help="Use onflict rule. (--no-conflict-rule)"/>
+            </when>
+        </conditional>
     </inputs>
-    
     <outputs>
-	<data format="txt" name="stdout" label="${tool.name} on ${on_string}" />
+        <data format="txt" name="stdout" label="${tool.name} on ${on_string}" />
     </outputs>
-    
     <tests>
-	<test>
-	    <param name="mea_parameter_selector" value="default" />
-
-	    <param name="predict_selector" value="predict" />
-	    <param name="compare_selector"  value="true" />
-
-	    <param name="dotplot" value="test_dp.ps" />
-	    <param name="reference" value="test_reference.txt" />
-	    
-	    <output name="stdout" file="test_predict.out" />
-	</test>
-	
-	<test>
-	    <param name="mea_parameter_selector" value="default" />
-	    <param name="predict_selector" value="compare" />
-	    <param name="compare_selector" value="true" />
-
-	    <param name="structure" value="test_structure.txt" />
-	    <param name="reference" value="test_reference.txt" />
-
-	    <output name="stdout" file="test_compare.out" />
-	</test>
+        <test>
+            <param name="mea_parameter_selector" value="default" />
+            <param name="predict_selector" value="predict" />
+            <param name="compare_selector"  value="compare" />
+            <param name="dotplot" value="test_dp.ps" />
+            <param name="reference" value=".....(((.((((((..((......))....)))))).)))...((((((((.(((..(((....))).............))).))).)))))" />
+            <output name="stdout" file="test_predict.out" />
+        </test>
+        <test>
+            <param name="mea_parameter_selector" value="default" />
+            <param name="predict_selector" value="compare" />
+            <param name="compare_selector" value="compare" />
+            <param name="structure" value=".....(((.((((((..((......))....)))))).)))......(((((.(((.....(((....))).........).)).))).))..." />
+            <param name="reference" value=".....(((.((((((..((......))....)))))).)))...((((((((.(((..(((....))).............))).))).)))))" />
+            <output name="stdout" file="test_compare.out" />
+        </test>
     </tests>
-    
-
     <help><![CDATA[
 =====
 MEA
 =====
 
-MEA predicts RNA maximum expected accuracy structures from RNA base
-pair probabilities and optionally compares them to a reference
-structure. In a special mode it skips the prediction and compares a
+`MEA <http://www.bioinf.uni-leipzig.de/Software/mea/>`_ predicts RNA maximum expected accuracy structures from RNA base pair probabilities and optionally compares them to a reference structure. In a special mode it skips the prediction and compares a
 given structure to the reference.  For the prediction, MEA allows to
 penalize long base pairs, using parameters alpha, beta, gamma, and
 delta. For the comparison of secondary structures, several measures
@@ -188,7 +158,7 @@
 
 * TN   = # true negatives
 
-* SENS = TP/(TP+FN) 'Sensitivity'
+* SENS = TP/(TP+FN) 'Sensitivity'http://www.bioinf.uni-leipzig.de/Software/mea/
 
 * PPV  = TP/(TP+FP) 'Positive Predictive Value'
 
@@ -201,23 +171,14 @@
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
 * Slide rule: tolerate shift of one base pair end by one base. This
-rule directly affects the number of true positives.  
-
+  rule directly affects the number of true positives.  
 * Conflict rule: predicted base pairs are false only if they
-conflict with the reference; two base pair conflict if and only if
-they share one end This rule directly affects the number of false
-positives.
+  conflict with the reference; two base pair conflict if and only if
+  they share one end This rule directly affects the number of false
+  positives.
 
---------
-Download
---------
-
-The command line tool MEA is free software available for download and
-local installation at
-.. __: http://www.bioinf.uni-leipzig.de/Software/mea/
     ]]></help>
     <citations>
-	<citation type="doi">10.1007/978-3-319-02624-4_1</citation>
+        <citation type="doi">10.1007/978-3-319-02624-4_1</citation>
     </citations>
-
 </tool>
--- a/test-data/test_reference.txt	Thu Dec 10 12:22:08 2015 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,1 +0,0 @@
-.....(((.((((((..((......))....)))))).)))...((((((((.(((..(((....))).............))).))).)))))
--- a/test-data/test_structure.txt	Thu Dec 10 12:22:08 2015 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,2 +0,0 @@
-.....(((.((((((..((......))....)))))).)))......(((((.(((.....(((....))).........).)).))).))...
-
--- a/tool_dependencies.xml	Thu Dec 10 12:22:08 2015 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,29 +0,0 @@
-<?xml version="1.0"?>
-<tool_dependency>
-    <package name="gengetopt" version="2.22.6">
-        <repository changeset_revision="9d2ed370989c" name="package_gengetopt_2_22_6" owner="iuc" prior_installation_required="True" toolshed="https://testtoolshed.g2.bx.psu.edu" />
-    </package>
-    <package name="mea" version="0.6.4">
-        <install version="1.0">
-            <actions>
-              <action type="download_by_url">
-		http://www.bioinf.uni-leipzig.de/Software/mea/mea-0.6.4.tar.gz
-	      </action>
-
-              <action type="set_environment_for_install">
-                <repository changeset_revision="9d2ed370989c" name="package_gengetopt_2_22_6" owner="iuc" toolshed="https://testtoolshed.g2.bx.psu.edu">
-                  <package name="gengetopt" version="2.22.6" />
-                </repository>
-              </action>
-	      
-              <action type="autoconf" />
-	      
-              <action type="set_environment">
-                <environment_variable action="prepend_to" name="PATH">$INSTALL_DIR/bin</environment_variable>
-		<environment_variable action="set_to" name="MEA_ROOT_PATH">$INSTALL_DIR</environment_variable>
-              </action>
-            </actions>
-        </install>
-        <readme>Compiling MEA requires a C++ compiler (usually g++)</readme>
-    </package>
-</tool_dependency>