# HG changeset patch # User greg # Date 1486146926 18000 # Node ID 7e92ab9ee98aa50e70a36a7bb0f3322d592c8be8 # Parent 6b547036c627dd2cf5de792555de3ceb772879be Uploaded diff -r 6b547036c627 -r 7e92ab9ee98a phylogenomics_analysis.xml --- a/phylogenomics_analysis.xml Thu Feb 02 14:41:59 2017 -0500 +++ b/phylogenomics_analysis.xml Fri Feb 03 13:35:26 2017 -0500 @@ -1,5 +1,5 @@ - - by creating multiple sequence alignments and inferred maximum likelihood phylogenies + + and inferred maximum likelihood phylogenies plant_tribes_phylogenomics_analysis @@ -16,36 +16,54 @@ #import os #import sys - #set scaffold_path = $scaffold.fields.path - #set scaffold_dir = $os.path.split($scaffold_path)[0] - #set scaffold_selection = $os.path.split($scaffold_path)[1] - #set src_fasta_dir = $os.path.join('phylogenomicsAnalysis_dir', 'orthogroups_fasta') - #if str($input.ext) == 'ptcgf': - #set dest_fasta_dir = $output_fasta_ptcgf.extra_files_path - else: - #set dest_fasta_dir =$output_fasta_ptcgfcs.extra_files_path - #end if + #set input_format = $input_format_cond.input_format + #set pipeline_output_dir = 'phylogenomicsAnalysis_dir' + #set scaffold_path = $scaffold.fields.path + #set scaffold_dir = $os.path.split($scaffold_path)[0] + #set scaffold_selection = $os.path.split($scaffold_path)[1] + #set src_aln_dir = $os.path.join($pipeline_output_dir, 'orthogroups_aln') + #set src_fasta_dir = $os.path.join($pipeline_output_dir, 'orthogroups_fasta') + #set src_tree_dir = $os.path.join($pipeline_output_dir, 'orthogroups_tree' - #if str($options_type.options_type_selector) == 'advanced' and str($options_type.multiple_sequence_alignments_cond.multiple_sequence_alignments) == 'yes': - #set generate_output_aln = True - #set src_aln_dir = $os.path.join('phylogenomicsAnalysis_dir', 'orthogroups_aln') - #set dest_aln_dir = $output_aln.extra_files_path - mkdir -p $dest_aln_dir && + #if str($input_format) == 'ptcgf': + #set dest_fasta_dir = $output_fasta_ptcgf.extra_files_path + #set multiple_codon_alignments = 'no' + #set use_corresponding_coding_sequences = 'no #else: - #set generate_output_aln = False + ## str($input_format) == 'ptcgfcs': + #set dest_fasta_dir = $output_fasta_ptcgfcs.extra_files_path + #set multiple_codon_alignments_cond = $input_format_cond.multiple_codon_alignments_cond + #set multiple_codon_alignments = $multiple_codon_alignments_cond.multiple_codon_alignments + #if str($multiple_codon_alignments) == 'yes': + #set use_corresponding_coding_sequences_cond = $multiple_codon_alignments_cond.use_corresponding_coding_sequences_cond + #set use_corresponding_coding_sequences = $use_corresponding_coding_sequences_cond.use_corresponding_coding_sequences + #else: + #set use_corresponding_coding_sequences = 'no' + #end if #end if + mkdir -p $dest_fasta_dir && + + #if str($options_type.options_type_selector) == 'advanced': + #set multiple_sequence_alignments_cond = $options_type.multiple_sequence_alignments_cond + #set multiple_sequence_alignments = $multiple_sequence_alignments_cond.multiple_sequence_alignments + #if str($multiple_sequence_alignments) == 'yes': + #set multiple_sequence_alignments_option_cond = $options_type.multiple_sequence_alignments_cond.multiple_sequence_alignments_option_cond + #set multiple_sequence_alignments_option = $multiple_sequence_alignments_option_cond.multiple_sequence_alignments_option + #set generate_output_aln = True + #set dest_aln_dir = $output_aln.extra_files_path + mkdir -p $dest_aln_dir && + #else: + #set generate_output_aln = False + #end if #if str($options_type.options_type_selector) == 'advanced' and str($options_type.phylogenetic_trees_cond.phylogenetic_trees) == 'yes': #set generate_output_tree = True - #set src_tree_dir = $os.path.join('phylogenomicsAnalysis_dir', 'orthogroups_tree') #set dest_tree_dir = $output_tree.extra_files_path mkdir -p $dest_tree_dir && #else: #set generate_output_tree = False #end if - mkdir -p $dest_fasta_dir && - PhylogenomicsAnalysis --num_threads \${GALAXY_SLOTS:-4} --orthogroup_faa '$input.extra_files_path' @@ -54,33 +72,7 @@ --method $method #if str($options_type.options_type_selector) == 'advanced': - #if str($options_type.multiple_sequence_alignments_cond.multiple_sequence_alignments) == 'yes': - #set multiple_sequence_alignments_option_cond = $options_type.multiple_sequence_alignments_cond.multiple_sequence_alignments_option_cond - #set multiple_sequence_alignments_option = $multiple_sequence_alignments_option_cond.multiple_sequence_alignments_option - #if str($multiple_sequence_alignments_option) == 'create_alignments': - #set multiple_sequence_alignments_option_str = 'Create alignments (MAFFT algorithm)' - #else if str($multiple_sequence_alignments_option) == 'add_alignments': - #set multiple_sequence_alignments_option_str = 'Add proteins to alignments (MAFFT algorithm)' - #else if str($multiple_sequence_alignments_option) == 'pasta_alignments': - #set multiple_sequence_alignments_option_str = 'Create alignments (PASTA algorithm)' - #end if - - #set input_includes_coding_sequences_cond = $options_type.multiple_sequence_alignments_cond.input_includes_coding_sequences_cond - #set input_includes_coding_sequences = $input_includes_coding_sequences_cond.input_includes_coding_sequences - #if str($input_includes_coding_sequences) == 'yes': - #set multiple_codon_alignments_cond = $input_includes_coding_sequences_cond.multiple_codon_alignments_cond - #set multiple_codon_alignments = $multiple_codon_alignments_cond.multiple_codon_alignments - #if str($multiple_codon_alignments) == 'yes': - #set use_corresponding_coding_sequences_cond = $multiple_codon_alignments_cond.use_corresponding_coding_sequences_cond - #set use_corresponding_coding_sequences = $use_corresponding_coding_sequences_cond.use_corresponding_coding_sequences - #else: - #set use_corresponding_coding_sequences = 'no' - #end if - #else: - #set multiple_codon_alignments = 'no' - #set use_corresponding_coding_sequences = 'no' - #end if - + #if str($multiple_sequence_alignments) == 'yes': #if str($multiple_sequence_alignments_option) == 'create_alignments': --create_alignments #else if str($multiple_sequence_alignments_option) == 'add_alignments': @@ -90,20 +82,6 @@ --pasta_alignments --pasta_iter_limit $multiple_sequence_alignments_option_cond.pasta_iter_limit #end if - - #if str($input_includes_coding_sequences) == 'yes': - #if str($multiple_codon_alignments) == 'yes': - --codon_alignments - #if str($use_corresponding_coding_sequences) == 'yes': - #if str($input.ext) == 'ptcgfcs): - --orthogroup_fna - #else: - raise Exception("Selected input does not include corresponding coding sequences") - #end if - #end if - --sequence_type $multiple_codon_alignments_cond.sequence_type - #end if - #end if #end if #if str($options_type.phylogenetic_trees_cond.phylogenetic_trees) == 'yes': @@ -137,13 +115,14 @@ #end if #end if - #if str($input.ext) == 'ptcgf': - && echo "Sequence alignments and corresponding phylogenies: `ls $src_fasta_dir | grep f | wc -l` files" > $output_fasta_ptcgf - && ls -al $src_fasta_dir | grep f >> $output_fasta_ptcgf - #else: - && echo "Sequence alignments and corresponding phylogenies: `ls $src_fasta_dir | grep f | wc -l` files" > $output_fasta_ptcgfcs - && ls -al $src_fasta_dir | grep f >> $output_fasta_ptcgfcs - #end if + #if str($input_format) == 'ptcgf': + && echo "Sequence alignments and corresponding phylogenies: `ls $src_fasta_dir | grep f | wc -l` files" > $output_fasta_ptcgf + && ls -al $src_fasta_dir | grep f >> $output_fasta_ptcgf + #else: + && echo "Sequence alignments and corresponding phylogenies: `ls $src_fasta_dir | grep f | wc -l` files" > $output_fasta_ptcgfcs + && ls -al $src_fasta_dir | grep f >> $output_fasta_ptcgfcs + #end if + && mv $src_fasta_dir/* $dest_fasta_dir || true #if $generate_output_aln: @@ -160,10 +139,42 @@ ]]> - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + @@ -196,36 +207,6 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -292,11 +273,11 @@ - - input.ext == 'ptcgf' + + input_format_cond['input_format] == 'ptcgf' - - input.ext == 'ptcgfcs' + + input_format_cond['input_format] == 'ptcgfcs' options_type['options_type_selector'] == 'advanced' and options_type['multiple_sequence_alignments_cond']['multiple_sequence_alignments'] == 'yes'