comparison vcfs2fasta.xml @ 14:f72039c5faa4 draft

Uploaded
author ulfschaefer
date Wed, 16 Dec 2015 07:29:05 -0500
parents
children a2ffbf5f50c1
comparison
equal deleted inserted replaced
13:2e69ce9dca65 14:f72039c5faa4
1 <tool id="vcfs2fasta" name="VCFs to fasta" version="1.0">
2 <description>Takes a set of VCF files and outputs a multi fasta file with only the variant positions.</description>
3 <requirements>
4 <requirement type="package" version="2.7.10">python</requirement>
5 <requirement type="package" version="0.6.7">pyvcf</requirement>
6 <requirement type="package" version="3.11">pyyaml</requirement>
7 <requirement type="package" version="2.0.2">bintrees</requirement>
8 <requirement type="package" version="1.66">biopython</requirement>
9 <requirement type="package" version="1.4">matplotlib</requirement>
10 </requirements>
11 <stdio>
12 <!-- Assume anything other than zero is an error -->
13 <exit_code range="1:" />
14 <exit_code range=":-1" />
15 </stdio>
16 <command interpreter="bash">
17 vcfs2fasta.sh
18 $output
19 #if str($mix_cond.mix) == "yes":
20 $mix_cond.mix_value
21 #else
22 NOTTHERE
23 #end if
24 #if str($cols_cond.cols) == "yes":
25 $cols_cond.column_ns
26 #else
27 NOTTHERE
28 #end if
29 #if str($sample_cond.sample) == "yes":
30 $sample_cond.sample_ns
31 #else
32 NOTTHERE
33 #end if
34 #if str($reference_cond.reference) == "yes":
35 $reference_cond.ref_fa
36 #else
37 NOTTHERE
38 #end if
39 #if str($include_cond.include) == "yes":
40 $include_cond.in_bed
41 #else
42 NOTTHERE
43 #end if
44 #if str($exclude_cond.exclude) == "yes":
45 $exclude_cond.ex_bed
46 #else
47 NOTTHERE
48 #end if
49 #for $i, $input_vcf in enumerate( $input_vcfs ):
50 "${input_vcf}"
51 #end for
52 </command>
53
54 <inputs>
55 <param name="input_vcfs" type="data" multiple="true" format="vcf" label="Input VCF file(s)" />
56 <conditional name="mix_cond">
57 <param name="mix" type="select" label="With Mixtures" help="Specify this option with a threshold to output mixtures above this threshold.">
58 <option value="yes">Specify</option>
59 <option value="no" selected="true">Do not specify</option>
60 </param>
61 <when value="yes">
62 <param name="mix_value" type="float" value="0.5" label="Mixture value" />
63 </when>
64 </conditional>
65 <conditional name="cols_cond">
66 <param name="cols" type="select" label="Column Ns" help="Keeps columns with fraction of Ns above specified threshold.">
67 <option value="yes">Specify</option>
68 <option value="no" selected="true">Do not specify</option>
69 </param>
70 <when value="yes">
71 <param name="column_ns" type="float" value="0.5" label="Column Ns value" />
72 </when>
73 </conditional>
74 <conditional name="sample_cond">
75 <param name="sample" type="select" label="Sample Ns" help="Keeps samples with fraction of Ns above specified threshold.">
76 <option value="yes">Specify</option>
77 <option value="no" selected="true">Do not specify</option>
78 </param>
79 <when value="yes">
80 <param name="sample_ns" type="float" value="0.5" label="Sample Ns value" />
81 </when>
82 </conditional>
83 <conditional name="reference_cond">
84 <param name="reference" type="select" label="Reference genome file" help="If path to reference specified, then whole genome will be outputted.">
85 <option value="yes">Specify</option>
86 <option value="no" selected="true">Do not specify</option>
87 </param>
88 <when value="yes">
89 <param name="ref_fa" type="data" format="fasta" label="Reference fasta file" help="Fasta format"/>
90 </when>
91 </conditional>
92 <conditional name="include_cond">
93 <param name="include" type="select" label="Include region" help="Specify regions to include in a bed file.">
94 <option value="yes">Specify</option>
95 <option value="no" selected="true">Do not specify</option>
96 </param>
97 <when value="yes">
98 <param name="in_bed" type="data" format="bed" label="Include regions bed file" help="bed format"/>
99 </when>
100 </conditional>
101 <conditional name="exclude_cond">
102 <param name="exclude" type="select" label="Exclude region" help="Specify regions to exclude in a bed file.">
103 <option value="yes">Specify</option>
104 <option value="no" selected="true">Do not specify</option>
105 </param>
106 <when value="yes">
107 <param name="ex_bed" type="data" format="bed" label="Exclude regions bed file" help="bed format"/>
108 </when>
109 </conditional>
110 </inputs>
111
112 <outputs>
113 <data format="fasta" name="output" label="${tool.name} on ${on_string}: FASTA file" />
114 </outputs>
115 <test>
116 <param name="input_vcfs" value="1_short.vcf" ftype="vcf" />
117 <param name="input_vcfs" value="2_short.vcf" ftype="vcf" />
118 <output name="output" file="testresult.fa" ftype="fasta" />
119 </test>
120 <help>
121
122 </help>
123 </tool>