comparison add_fst_column.xml @ 27:8997f2ca8c7a

Update to Miller Lab devshed revision bae0d3306d3b
author Richard Burhans <burhans@bx.psu.edu>
date Mon, 15 Jul 2013 10:47:35 -0400
parents 248b06e86022
children a631c2f6d913
comparison
equal deleted inserted replaced
26:91e835060ad2 27:8997f2ca8c7a
1 <tool id="gd_add_fst_column" name="Per-SNP FSTs" version="1.2.0"> 1 <tool id="gd_add_fst_column" name="Per-SNP FSTs" version="1.2.0">
2 <description>: Compute a fixation index score for each SNP</description> 2 <description>: Compute a fixation index score for each SNP</description>
3 3
4 <command interpreter="python"> 4 <command interpreter="python">
5 add_fst_column.py "$input" "$p1_input" "$p2_input" 5 #import json
6 #import base64
7 #import zlib
8 #set $ind_names = $input.dataset.metadata.individual_names
9 #set $ind_colms = $input.dataset.metadata.individual_columns
10 #set $ind_dict = dict(zip($ind_names, $ind_colms))
11 #set $ind_json = json.dumps($ind_dict, separators=(',',':'))
12 #set $ind_comp = zlib.compress($ind_json, 9)
13 #set $ind_arg = base64.b64encode($ind_comp)
14 add_fst_column.py '$input' '$p1_input' '$p2_input'
6 #if $input_type.choice == '0' 15 #if $input_type.choice == '0'
7 "gd_snp" "$input_type.data_source.choice" 16 'gd_snp' '$input_type.data_source.choice'
8 #if $input_type.data_source.choice == '0' 17 #if $input_type.data_source.choice == '0'
9 "$input_type.data_source.min_reads" "$input_type.data_source.min_qual" 18 '$input_type.data_source.min_reads' '$input_type.data_source.min_qual'
10 #else if $input_type.data_source.choice == '1' 19 #else if $input_type.data_source.choice == '1'
11 "0" "0" 20 '0' '0'
12 #end if 21 #end if
13 #else if $input_type.choice == '1' 22 #else if $input_type.choice == '1'
14 "gd_genotype" "1" "0" "0" 23 'gd_genotype' '1' '0' '0'
15 #end if 24 #end if
16 "$retain" "$discard_fixed" "$biased" "$output" 25 '$retain' '$discard_fixed' '$biased' '$output' '$ind_arg'
17 #for $individual, $individual_col in zip($input.dataset.metadata.individual_names, $input.dataset.metadata.individual_columns)
18 #set $arg = '%s:%s' % ($individual_col, $individual)
19 "$arg"
20 #end for
21 </command> 26 </command>
22 27
23 <inputs> 28 <inputs>
24 <conditional name="input_type"> 29 <conditional name="input_type">
25 <param name="choice" type="select" format="integer" label="Input format"> 30 <param name="choice" type="select" format="integer" label="Input format">