diff frogsfunc_functions.xml @ 27:646bee69560f draft

planemo upload for repository https://github.com/geraldinepascal/FROGS-wrappers/ commit b6afc353bed8654c3a9ca56d194ecc7827d9ca18
author oinizan
date Wed, 30 Apr 2025 06:13:02 +0000
parents 9cb4b18902d9
children fce825ec2c84
line wrap: on
line diff
--- a/frogsfunc_functions.xml	Thu Apr 03 05:58:59 2025 +0000
+++ b/frogsfunc_functions.xml	Wed Apr 30 06:13:02 2025 +0000
@@ -24,38 +24,36 @@
 
   <expand macro="requirements_frogsfunc" />
 
+  <command detect_errors="exit_code">
+        <![CDATA[ 
+        frogsfunc_functions.py
+                @CPUS@
+                --input-biom $input_biom
+                --input-fasta $input_fasta
+                --input-tree $input_tree
+                --input-marker $input_marker
+                --marker-type $category.value
 
-    <stdio>
-        <exit_code range="1:" />
-        <exit_code range=":-1" />
-    </stdio>
-    <code file="functions_validator.py" />
-    <command >
-       frogsfunc_functions.py
-            @CPUS@
-            --input-biom $input_biom
-            --input-fasta $input_fasta
-            --input-tree $input_tree
-            --input-marker $input_marker
-            --marker-type $category.value
-            #if $category.value == "16S"
-                --functions $functions
-            #end if
-            #if $category.value != "16S"
-                --input-function-table $functions.fields.traits
-            #end if 
-            --max-nsti $max_nsti
-            --min-blast-ident $min_blast_ident
-            --min-blast-cov $min_blast_cov
-	   		--hsp-method $hsp_method
-            --output-biom $output_biom
-            --output-fasta $output_fasta
-            --output-function-abund "frogsfunc_functions_unstrat.tsv"
-            --output-otu-norm $output_otu_norm
-            --output-weighted $output_weighted
-            --output-excluded $output_excluded
-            --summary $summary_file
+                #if $category.value == "16S"
+                    --functions $functions
+                #end if
+
+                #if $category.value != "16S"
+                    --input-function-table $functions.fields.traits
+                #end if 
 
+                --max-nsti $max_nsti
+                --min-blast-ident $min_blast_ident
+                --min-blast-cov $min_blast_cov
+                --hsp-method $hsp_method
+                --output-biom $output_biom
+                --output-fasta $output_fasta
+                --output-function-abund "frogsfunc_functions_unstrat.tsv"
+                --output-otu-norm $output_otu_norm
+                --output-weighted $output_weighted
+                --output-excluded $output_excluded
+                --summary $summary_file
+        ]]>
     </command> 
     <inputs>
         <!-- Input files -->
@@ -80,6 +78,7 @@
 				<column name='path' index='2' />
 				<column name='traits' index='3' />
                 <filter type="param_value" ref="category" column="0" />   
+ 		<validator type="expression" message="'EC' is the default database used by PICRUSt2. 'EC' or 'KO' must be at least selected. Other tables are optionnal">"EC" in value or "KO" in value</validator>               
             </options>
         </param>
         <param argument="--max-nsti" type="float" label="NSTI cut-off" help="Any sequence with an NSTI above this threshold will be out. (default: 2)" value="2" min="0" optional="false" />
@@ -93,6 +92,7 @@
             <option value="subtree_average">subtree_average</option>
 		</param>
     </inputs>
+
     <outputs>
         <data format="html" name="summary_file" label="${tool.name}: report.html" from_work_dir="report.html"/>
 		<data format="biom1" name="output_biom" label="${tool.name}: frogsfunc_functions_asv_abundances.biom" from_work_dir="frogsfunc_functions.biom"/>
@@ -139,14 +139,13 @@
         </data>
     </outputs>
 
-
     <tests>
-        <test>
+        <test expect_num_outputs="8">
             <param name="input_fasta" value="references/25-frogsfunc_placeseqs.fasta" />
             <param name="input_biom" value="references/25-frogsfunc_placeseqs.biom" />
             <param name="input_tree" value="references/25-frogsfunc_placeseqs_tree.nwk" />
             <param name="input_marker" value="references/25-frogsfunc_copynumbers_marker.tsv" />
-            <param name="category.value" value="frogs_picrust2_functions" />
+            <param name="category" value="16S" />
             <param name="functions" value="EC" />
             <param name="max_nsti" value="2" />