comparison phylogenetic_tree.xml @ 24:248b06e86022

Added gd_genotype datatype. Modified tools to support new datatype.
author Richard Burhans <burhans@bx.psu.edu>
date Tue, 28 May 2013 16:24:19 -0400
parents f04f40a36cc8
children 8997f2ca8c7a
comparison
equal deleted inserted replaced
23:66a183c44dd5 24:248b06e86022
1 <tool id="gd_phylogenetic_tree" name="Phylogenetic Tree" version="1.0.0"> 1 <tool id="gd_phylogenetic_tree" name="Phylogenetic Tree" version="1.1.0">
2 <description>: Show genetic relationships among individuals</description> 2 <description>: Show genetic relationships among individuals</description>
3 3
4 <command interpreter="python"> 4 <command interpreter="python">
5 phylogenetic_tree.py "$input" 5 phylogenetic_tree.py "$input" "$output" "$output.files_path"
6
7 #if $input_type.choice == '0'
8 "gd_snp"
9 #if $input_type.data_source.choice == '0'
10 "sequence_coverage"
11 "$input_type.data_source.minimum_coverage"
12 "$input_type.data_source.minimum_quality"
13 #else if $input_type.data_source.choice == '1'
14 "estimated_genotype"
15 #end if
16 #else if $input_type.choice == '1'
17 "gd_genotype"
18 #end if
19
6 #if $individuals.choice == '0' 20 #if $individuals.choice == '0'
7 "all_individuals" 21 "all_individuals"
8 #else if $individuals.choice == '1' 22 #else if $individuals.choice == '1'
9 "$p1_input" 23 "$individuals.p1_input"
10 #end if 24 #end if
11 "$output" "$output.files_path" "$minimum_coverage" "$minimum_quality" 25
12 #if ((str($input.metadata.scaffold) == str($input.metadata.ref)) and (str($input.metadata.pos) == str($input.metadata.rPos))) or (str($include_reference) == '0') 26 #if ((str($input.metadata.scaffold) == str($input.metadata.ref)) and (str($input.metadata.pos) == str($input.metadata.rPos))) or (str($include_reference) == '0')
13 "none" 27 "none"
14 #else 28 #else
15 "$input.metadata.dbkey" 29 "$input.metadata.dbkey"
16 #end if 30 #end if
17 "$data_source" 31
18 #set $draw_tree_options = ''.join(str(x) for x in [$branch_style, $scale_style, $length_style, $layout_style]) 32 #set $draw_tree_options = ''.join(str(x) for x in [$branch_style, $scale_style, $length_style, $layout_style])
19 #if $draw_tree_options == '' 33 #if $draw_tree_options == ''
20 "" 34 ""
21 #else 35 #else
22 "-$draw_tree_options" 36 "-$draw_tree_options"
23 #end if 37 #end if
38
24 #for $individual_name, $individual_col in zip($input.dataset.metadata.individual_names, $input.dataset.metadata.individual_columns) 39 #for $individual_name, $individual_col in zip($input.dataset.metadata.individual_names, $input.dataset.metadata.individual_columns)
25 #set $arg = '%s:%s' % ($individual_col, $individual_name) 40 #set $arg = '%s:%s' % ($individual_col, $individual_name)
26 "$arg" 41 "$arg"
27 #end for 42 #end for
28 </command> 43 </command>
29 44
30 <inputs> 45 <inputs>
31 <param name="input" type="data" format="gd_snp" label="SNP dataset" /> 46 <conditional name="input_type">
47 <param name="choice" type="select" format="integer" label="Input format">
48 <option value="0" selected="true">gd_snp</option>
49 <option value="1">gd_genotype</option>
50 </param>
51 <when value="0">
52 <param name="input" type="data" format="gd_snp" label="SNP dataset" />
53
54 <conditional name="data_source">
55 <param name="choice" type="select" format="integer" label="Distance metric">
56 <option value="0">sequence coverage</option>
57 <option value="1" selected="true">estimated genotype</option>
58 </param>
59 <when value="0">
60 <param name="minimum_coverage" type="integer" min="0" value="0" label="Minimum SNP coverage" />
61 <param name="minimum_quality" type="integer" min="0" value="0" label="Minimum SNP quality"
62 help="Note: minimum coverage and minimum quality cannot both be 0" />
63 </when>
64 <when value="1"/>
65 </conditional>
66 </when>
67 <when value="1">
68 <param name="input" type="data" format="gd_genotype" label="Genotype dataset" />
69 </when>
70 </conditional>
32 71
33 <conditional name="individuals"> 72 <conditional name="individuals">
34 <param name="choice" type="select" label="Compute for"> 73 <param name="choice" type="select" label="Compute for">
35 <option value="0" selected="true">All individuals</option> 74 <option value="0" selected="true">All individuals</option>
36 <option value="1">Individuals in a population</option> 75 <option value="1">Individuals in a population</option>
39 <when value="1"> 78 <when value="1">
40 <param name="p1_input" type="data" format="gd_indivs" label="Population individuals" /> 79 <param name="p1_input" type="data" format="gd_indivs" label="Population individuals" />
41 </when> 80 </when>
42 </conditional> 81 </conditional>
43 82
44 <param name="minimum_coverage" type="integer" min="0" value="0" label="Minimum SNP coverage" />
45
46 <param name="minimum_quality" type="integer" min="0" value="0" label="Minimum SNP quality"
47 help="Note: minimum coverage and minimum quality cannot both be 0" />
48
49 <param name="include_reference" type="select" format="integer" label="Include reference sequence"> 83 <param name="include_reference" type="select" format="integer" label="Include reference sequence">
50 <option value="1" selected="true">Yes</option> 84 <option value="1" selected="true">Yes</option>
51 <option value="0">No</option> 85 <option value="0">No</option>
52 </param>
53
54 <param name="data_source" type="select" format="integer" label="Distance metric">
55 <option value="0" selected="true">sequence coverage</option>
56 <option value="1">estimated genotype</option>
57 </param> 86 </param>
58 87
59 <param name="branch_style" type="select" display="radio"> 88 <param name="branch_style" type="select" display="radio">
60 <label>Branch type</label> 89 <label>Branch type</label>
61 <option value="" selected="true">square</option> 90 <option value="" selected="true">square</option>
108 137
109 <help> 138 <help>
110 139
111 **Dataset formats** 140 **Dataset formats**
112 141
113 The input dataset is in gd_snp_ format. 142 The input dataset is in gd_snp_ or gd_genotype_ format.
114 The output is a composite dataset, containing the tree in both text (Newick_) 143 The output is a composite dataset, containing the tree in both text (Newick_)
115 and PostScript formats, as well as supplemental text information. 144 and PostScript formats, as well as supplemental text information.
116 (`Dataset missing?`_) 145 (`Dataset missing?`_)
117 146
118 .. _gd_snp: ./static/formatHelp.html#gd_snp 147 .. _gd_snp: ./static/formatHelp.html#gd_snp
148 .. _gd_genotype: ./static/formatHelp.html#gd_genotype
119 .. _Newick: http://evolution.genetics.washington.edu/phylip/newicktree.html 149 .. _Newick: http://evolution.genetics.washington.edu/phylip/newicktree.html
120 .. _Dataset missing?: ./static/formatHelp.html 150 .. _Dataset missing?: ./static/formatHelp.html
121 151
122 ----- 152 -----
123 153