|
0
|
1 <tool id="covacs_varsca2" name="covacs_varscan2" version="2.4.2">
|
|
|
2 <description>varscan2 wrapper for covacs</description>
|
|
|
3 <requirements>
|
|
|
4 <requirement type="package" version="2.4.2">varscan</requirement>
|
|
|
5 </requirements>
|
|
|
6 <macros>
|
|
|
7 <import>bed_macros.xml</import>
|
|
|
8 </macros>
|
|
|
9 <stdio>
|
|
|
10 <regex match="Exception" source="both" level="fatal" description="Tool exception"/>
|
|
|
11 <regex match=".*" source="both" level="log" description="tool progress"/>
|
|
|
12 </stdio>
|
|
|
13
|
|
|
14 <version_command><![CDATA[
|
|
|
15 varscan 2>&1 | head -n 1
|
|
|
16 ]]></version_command>
|
|
|
17
|
|
|
18 <command><![CDATA[
|
|
|
19 ## Set up samples list file.
|
|
|
20 #if $sample_names.strip() != '':
|
|
|
21 echo $sample_names | awk -F ',' '{ for (i = 1; i <= NF; i++) { print \$i; } }' > samples_list.txt &&
|
|
|
22 #end if
|
|
|
23
|
|
|
24 ## Set up command + input.
|
|
|
25 varscan ${cmd} ${input}
|
|
|
26 --min-coverage ${min_coverage}
|
|
|
27 --min-reads2 ${min_supporting_reads}
|
|
|
28 --min-avg-qual ${min_avg_qual}
|
|
|
29 --min-var-freq ${min_var_freq}
|
|
|
30 --min-freq-for-hom ${min_freq_for_hom}
|
|
|
31 --p-value ${p_value}
|
|
|
32 #if str($strand_filter) == 'yes':
|
|
|
33 --strand-filter 1
|
|
|
34 #end if
|
|
|
35
|
|
|
36 ## Report only variants in consensus.
|
|
|
37 #if str($cmd) == 'mpileup2cns':
|
|
|
38 --variants
|
|
|
39 #end if
|
|
|
40
|
|
|
41 ## varscan bed limit added
|
|
|
42
|
|
|
43 #if $bed_source.bed_source_selector == "history" and $bed_source.bed_history
|
|
|
44 limit $bed_source.bed_history
|
|
|
45 #end if
|
|
|
46 #if $bed_source.bed_source_selector == "cached"
|
|
|
47 limit $bed_source.bed_cached.fields.path
|
|
|
48 #end if
|
|
|
49
|
|
|
50 ## Set up outputs.
|
|
|
51 --output-vcf 1 > $output
|
|
|
52
|
|
|
53 #if $sample_names.strip() != '':
|
|
|
54 --vcf-sample-list samples_list.txt
|
|
|
55 #end if
|
|
|
56
|
|
|
57 && perl $__tool_directory__/filter.varscan.pl $output $output_filtered
|
|
|
58 ]]></command>
|
|
|
59
|
|
|
60 <inputs>
|
|
|
61 <param format="pileup" name="input" type="data" label="Pileup dataset" help=""/>
|
|
|
62 <param name="cmd" type="select" label="Analysis type">
|
|
|
63 <option value="mpileup2snp" selected="True">single nucleotide variation</option>
|
|
|
64 <option value="mpileup2indel">insertions and deletions</option>
|
|
|
65 <option value="mpileup2cns">consensus genotype</option>
|
|
|
66 </param>
|
|
|
67 <expand macro="bed_loc"/>
|
|
|
68 <param name="min_coverage" type="integer" value="8" min="1" max="200" label="Minimum read depth" help="Minimum depth at a position to make a call"/>
|
|
|
69 <param name="min_supporting_reads" type="integer" value="2" min="1" max="200" label="Minimum supporting reads" help="Minimum supporting reads at a position to make a call"/>
|
|
|
70 <param name="min_avg_qual" type="integer" value="15" min="1" max="50" label="Minimum base quality at a position to count a read"/>
|
|
|
71 <param name="min_var_freq" type="float" value="0.01" min="0" max="1" label="Minimum variant allele frequency threshold"/>
|
|
|
72 <param name="min_freq_for_hom" type="float" value="0.75" min="0" max="1" label="Minimum frequency to call homozygote"/>
|
|
|
73 <param name="p_value" type="float" value="0.99" min="0" max="1" label="p-value threshold for calling variants"/>
|
|
|
74 <param name="strand_filter" type="select" label="Ignore variants with >90% support on one strand">
|
|
|
75 <option value="no" selected="True">no</option>
|
|
|
76 <option value="yes">yes</option>
|
|
|
77 </param>
|
|
|
78 <param name="sample_names" type="text" value="" help="Separate sample names by comma; leave blank to use default sample names."/>
|
|
|
79 </inputs>
|
|
|
80
|
|
|
81 <outputs>
|
|
|
82 <data name="output" format="vcf"/>
|
|
|
83 <data format="vcf" name="output_filtered" label="varscan2 filtered on ${on_string}" />
|
|
|
84 </outputs>
|
|
|
85 <tests>
|
|
|
86 <test>
|
|
|
87 <param name="input" value="test_in1.pileup" />
|
|
|
88 <param name="cmd" value="mpileup2cns" />
|
|
|
89 <param name="min_coverage" value="8" />
|
|
|
90 <param name="min_supporting_reads" value="2" />
|
|
|
91 <param name="min_avg_qual" value="15" />
|
|
|
92 <param name="min_var_freq" value="0.01" />
|
|
|
93 <param name="min_freq_for_hom" value="0.75" />
|
|
|
94 <param name="p_value" value="0.99" />
|
|
|
95 <param name="strand_filter" value="no" />
|
|
|
96 <param name="sample_names" value="" />
|
|
|
97 <output name="output" file="test_out1.vcf" lines_diff="0" />
|
|
|
98 </test>
|
|
|
99 </tests>
|
|
|
100
|
|
|
101 <help>
|
|
|
102 **VarScan Overview**
|
|
|
103
|
|
|
104 VarScan_ performs variant detection for massively parallel sequencing data, such as exome, WGS, and transcriptome data. It calls variants from a mpileup dataset and produces a VCF 4.1 Full documentation is available online_.
|
|
|
105
|
|
|
106 .. _VarScan: http://dkoboldt.github.io/varscan/
|
|
|
107 .. _online: http://dkoboldt.github.io/varscan/using-varscan.html
|
|
|
108
|
|
|
109 **Input**
|
|
|
110
|
|
|
111 ::
|
|
|
112
|
|
|
113 mpileup file - The SAMtools mpileup file
|
|
|
114
|
|
|
115 **the wrapper gives 2 output**
|
|
|
116
|
|
|
117 -the normal output of varscan2
|
|
|
118
|
|
|
119 -the output filtered by the filter.varscan.pl script implemented in the covacs pipeline
|
|
|
120
|
|
|
121
|
|
|
122
|
|
|
123 **Parameters**
|
|
|
124
|
|
|
125 ::
|
|
|
126
|
|
|
127 analysis type
|
|
|
128 single nucleotide detection Identify SNPs from an mpileup file
|
|
|
129 insertions and deletion Identify indels an mpileup file
|
|
|
130 consensus genotype Call consensus and variants from an mpileup file
|
|
|
131
|
|
|
132 min-coverage
|
|
|
133 Minimum read depth at a position to make a call [8]
|
|
|
134
|
|
|
135 min-reads2
|
|
|
136 Minimum supporting reads at a position to call variants [2]
|
|
|
137
|
|
|
138 min-avg-qual
|
|
|
139 Minimum base quality at a position to count a read [15]
|
|
|
140
|
|
|
141 min-var-freq
|
|
|
142 Minimum variant allele frequency threshold [0.01]
|
|
|
143
|
|
|
144 min-freq-for-hom
|
|
|
145 Minimum frequency to call homozygote [0.75]
|
|
|
146
|
|
|
147 p-value
|
|
|
148 Default p-value threshold for calling variants [99e-02]
|
|
|
149
|
|
|
150 strand-filter
|
|
|
151 Ignore variants with >90% support on one strand [1]
|
|
|
152
|
|
|
153 output-vcf
|
|
|
154 If set to 1, outputs in VCF format
|
|
|
155
|
|
|
156 vcf-sample-list
|
|
|
157 For VCF output, a list of sample names in order, one per line
|
|
|
158
|
|
|
159 variants
|
|
|
160 Report only variant (SNP/indel) positions [0]
|
|
|
161 </help>
|
|
|
162
|
|
|
163 <citations>
|
|
|
164 <citation type="doi">10.1101/gr.129684.111</citation>
|
|
|
165 <citation type="doi">10.1186/s12864-018-4508-1</citation>
|
|
|
166 </citations>
|
|
|
167 </tool>
|