diff macros.xml @ 99:de42cdf6e10b draft

Uploaded
author greg
date Mon, 27 Mar 2017 09:57:54 -0400
parents 56dbe45f4bfb
children 283f6666daf7
line wrap: on
line diff
--- a/macros.xml	Thu Mar 23 15:01:27 2017 -0400
+++ b/macros.xml	Mon Mar 27 09:57:54 2017 -0400
@@ -13,7 +13,7 @@
             <regex match="Exception:"/>
         </stdio>
     </xml>
-    <token name="@REMOVE_GAPPY_SEQUENCES_COND@">
+    <token name="@REMOVE_GAPPY_SEQUENCES_COND_PREP@">
         #set remove_gappy_sequences_cond = $options_type_cond.remove_gappy_sequences_cond
         #set remove_gappy_sequences = $remove_gappy_sequences_cond.remove_gappy_sequences
         #if str($remove_gappy_sequences) == 'no':
@@ -53,18 +53,57 @@
                     #set multiple_sequence_alignments_option = $multiple_sequence_alignments_option_cond.multiple_sequence_alignments_option
                     #if str($multiple_sequence_alignments_option) == 'pasta_alignments':
                         #set pasta_iter_limit = $multiple_sequence_alignments_option_cond.pasta_iter_limit
-                    #else if str($multiple_sequence_alignments_option) == 'iterative_realignments':
-                        #set iterative_realignments = $multiple_sequence_alignments_option_cond.iterative_realignments
+                    #else if str($multiple_sequence_alignments_option) == 'iterative_realignment':
+                        #set iterative_realignment = $multiple_sequence_alignments_option_cond.iterative_realignment
                     #end if
                 #end if
             #end if
         #end if
     </token>
-    <token name="@SET_PHYLOGENETIC_TREES@">
+    <token name="@REMOVE_GAPPY_SEQUENCES_COND_CMD@">
+        #if str($remove_gappy_sequences) == 'no':
+            #if str($multiple_sequence_alignments) == 'yes':
+                --alignments_method $multiple_sequence_alignments_option
+                #if str($multiple_sequence_alignments_option) == 'pasta_alignments':
+                    --pasta_script_path '$__tool_directory__/run_pasta.py'
+                    --pasta_iter_limit $pasta_iter_limit
+                #end if
+            #end if
+        #else:
+            ## str($remove_gappy_sequences) == 'yes':
+            --trim_type $trim_type
+            #if str($trim_type) == 'gap_trimming':
+                --gap_trimming $gap_trimming
+            #end if
+            #if str($remove_sequences_with_gaps) == 'no':
+                #if str($multiple_sequence_alignments) == 'yes':
+                    --alignments_method $multiple_sequence_alignments_option
+                    #if str($multiple_sequence_alignments_option) == 'pasta_alignments':
+                        --pasta_script_path '$__tool_directory__/run_pasta.py'
+                        --pasta_iter_limit $pasta_iter_limit
+                    #end if
+                #end if
+            #else:
+                ## str($remove_sequences_with_gaps) == 'yes':
+                --remove_sequences $remove_sequences_with_gaps_of
+                #if str($multiple_sequence_alignments) == 'yes':
+                    --alignments_method $multiple_sequence_alignments_option
+                    #if str($multiple_sequence_alignments_option) == 'pasta_alignments':
+                    #if str($multiple_sequence_alignments_option) == 'pasta_alignments':
+                        --pasta_script_path '$__tool_directory__/run_pasta.py'
+                        --pasta_iter_limit $pasta_iter_limit
+                    #else:
+                        --iterative_realignment $iterative_realignment
+                    #end if
+                #end if
+            #end if
+        #end if
+    </token>
+    <token name="@SET_PHYLOGENETIC_TREES_PREP@">
         #set phylogenetic_trees_cond = $options_type_cond.phylogenetic_trees_cond
         #set phylogenetic_trees = $phylogenetic_trees_cond.phylogenetic_trees
     </token>
-    <token name="@TREE_INFERENCE_COND@">
+    <token name="@TREE_INFERENCE_COND_PREP@">
         #set tree_inference_cond = $phylogenetic_trees_cond.tree_inference_cond
         #set tree_inference = $tree_inference_cond.tree_inference
         #if str($tree_inference) == 'raxml':
@@ -75,8 +114,21 @@
             #end if
             #set bootstrap_replicates = $tree_inference_cond.bootstrap_replicates
         #end if
+        #set min_orthogroup_size = $phylogenetic_trees_cond.min_orthogroup_size
         #set max_orthogroup_size = $phylogenetic_trees_cond.max_orthogroup_size
-        #set min_orthogroup_size = $phylogenetic_trees_cond.min_orthogroup_size
+    </token>
+    <token name="@TREE_INFERENCE_COND_CMD@">
+        --tree_inference $tree_inference
+        #if str($tree_inference) == 'raxml':
+            #if str($rooting_order_file) == 'yes':
+                --rooting_order '$rooting_order'
+                ## No else block needed here because the default rooting_order
+                ## configuration will be used if the --rooting_order flag is missing.
+            #end if
+            --bootstrap_replicates $bootstrap_replicates
+        #end if
+        --min_orthogroup_size $min_orthogroup_size
+        --max_orthogroup_size $max_orthogroup_size
     </token>
     <xml name="param_scaffold">
         <param name="scaffold" type="select" label="Orthogroups or gene families proteins scaffold">
@@ -142,10 +194,10 @@
             <expand macro="options_multiple_sequence_alignments_option" />
         </param>
     </xml>
-    <xml name="param_multiple_sequence_alignments_option_with_iterative_realignments">
+    <xml name="param_multiple_sequence_alignments_option_with_iterative_realignment">
         <param name="multiple_sequence_alignments_option" type="select" force_select="true" label="Select method for multiple sequence alignments">
             <expand macro="options_multiple_sequence_alignments_option" />
-            <option value="iterative_realignments">Iterative orthogroups realignment, trimming and fitering</option>
+            <option value="iterative_realignment">Iterative orthogroups realignment, trimming and fitering</option>
         </param>
     </xml>
     <xml name="whens_multiple_sequence_alignments_option_cond">
@@ -167,16 +219,16 @@
             </when>
         </conditional>
     </xml>
-    <xml name="cond_multiple_sequence_alignments_with_iterative_realignments">
+    <xml name="cond_multiple_sequence_alignments_with_iterative_realignment">
         <conditional name="multiple_sequence_alignments_cond">
             <expand macro="param_multiple_sequence_alignments" />
             <when value="no" />
             <when value="yes">
                 <conditional name="multiple_sequence_alignments_option_cond">
-                    <expand macro="param_multiple_sequence_alignments_option_with_iterative_realignments" />
+                    <expand macro="param_multiple_sequence_alignments_option_with_iterative_realignment" />
                     <expand macro="whens_multiple_sequence_alignments_option_cond" />
-                    <when value="iterative_realignments">
-                        <param name="iterative_realignments" type="integer" value="0" min="0" label="Maximum number of iterations" help="Zero value has no affect"/>
+                    <when value="iterative_realignment">
+                        <param name="iterative_realignment" type="integer" value="0" min="0" label="Maximum number of iterations" help="Zero value has no affect"/>
                     </when>
                 </conditional>
             </when>
@@ -282,7 +334,7 @@
                     </when>
                     <when value="yes">
                         <param name="remove_sequences_with_gaps_of" type="float" value="0.5" min="0" max="1" label="Remove sequences with gaps of" help="0.5 removes sequences with 50% gaps" />
-                        <expand macro="cond_multiple_sequence_alignments_with_iterative_realignments" />
+                        <expand macro="cond_multiple_sequence_alignments_with_iterative_realignment" />
                     </when>
                 </conditional>
             </when>