0
|
1 <tool id="gatk2_variant_annotator" name="Variant Annotator" version="0.0.7">
|
|
2 <description></description>
|
|
3 <expand macro="requirements" />
|
|
4 <macros>
|
|
5 <import>gatk2_macros.xml</import>
|
|
6 </macros>
|
|
7 <command interpreter="python">
|
|
8 gatk2_wrapper.py
|
|
9 --stdout "${output_log}"
|
|
10 #if str( $reference_source.input_bam ) != "None":
|
|
11 -d "-I" "${reference_source.input_bam}" "${reference_source.input_bam.ext}" "gatk_input"
|
|
12 #if str( $reference_source.input_bam.metadata.bam_index ) != "None":
|
|
13 -d "" "${reference_source.input_bam.metadata.bam_index}" "bam_index" "gatk_input" ##hardcode galaxy ext type as bam_index
|
|
14 #end if
|
|
15 #end if
|
|
16 -d "--variant" "${reference_source.input_variant}" "${reference_source.input_variant.ext}" "input_variant"
|
|
17 -p '
|
|
18 @JAR_PATH@
|
|
19 -T "VariantAnnotator"
|
|
20 \$GATK2_SITE_OPTIONS
|
|
21
|
|
22 @THREADS@
|
|
23
|
|
24 #if $reference_source.reference_source_selector != "history":
|
|
25 -R "${reference_source.ref_file.fields.path}"
|
|
26 #end if
|
|
27 -o "${output_vcf}"
|
|
28 #if str( $annotations_type.annotations_type_selector ) == "use_all_annotations":
|
|
29 --useAllAnnotations
|
|
30 #else:
|
|
31 #if $annotations_type.annotations:
|
|
32 #for $annotation in str( $annotations_type.annotations.fields.gatk_value ).split( ',' ):
|
|
33 --annotation "${annotation}"
|
|
34 #end for
|
|
35 #end if
|
|
36 #end if
|
|
37 #if $exclude_annotations:
|
|
38 #for $annotation in str( $exclude_annotations.fields.gatk_value ).split( ',' ):
|
|
39 --excludeAnnotation "${annotation}"
|
|
40 #end for
|
|
41 #end if
|
|
42 #for $additional_annotation in $additional_annotations:
|
|
43 --annotation "${additional_annotation.additional_annotation_name}"
|
|
44 #end for
|
|
45 '
|
|
46 #if $reference_source.input_variant_bti:
|
|
47 -d "--intervals" "${reference_source.input_variant}" "${reference_source.input_variant.ext}" "input_variant_bti"
|
|
48 #end if
|
|
49
|
|
50 #for $rod_binding in $comp_rod_bind:
|
|
51 -d "--comp:${rod_binding.comp_rod_name},%(file_type)s" "${rod_binding.comp_input_rod}" "${rod_binding.comp_input_rod.ext}" "input_comp_${rod_binding.comp_rod_name}"
|
|
52 #end for
|
|
53
|
|
54 #if str( $dbsnp_rod_bind_type.dbsnp_rod_bind_type_selector ) == 'set_dbsnp':
|
|
55 -d "--dbsnp:${dbsnp_rod_bind_type.dbsnp_rod_name},%(file_type)s" "${dbsnp_rod_bind_type.dbsnp_input_rod}" "${dbsnp_rod_bind_type.dbsnp_input_rod.ext}" "input_dbsnp_${dbsnp_rod_bind_type.dbsnp_rod_name}"
|
|
56 #end if
|
|
57
|
|
58
|
|
59 #for $rod_binding in $resource_rod_bind:
|
|
60 -d "--resource:${rod_binding.resource_rod_name},%(file_type)s" "${rod_binding.resource_input_rod}" "${rod_binding.resource_input_rod.ext}" "input_resource_${rod_binding.resource_rod_name}"
|
|
61 #end for
|
|
62
|
|
63 #if str( $snpEff_rod_bind_type.snpEff_rod_bind_type_selector ) == 'set_snpEff':
|
|
64 -p '--annotation "SnpEff"'
|
|
65 -d "--snpEffFile:${snpEff_rod_bind_type.snpEff_rod_name},%(file_type)s" "${snpEff_rod_bind_type.snpEff_input_rod}" "${snpEff_rod_bind_type.snpEff_input_rod.ext}" "input_snpEff_${snpEff_rod_bind_type.snpEff_rod_name}"
|
|
66 #else:
|
|
67 -p '--excludeAnnotation "SnpEff"'
|
|
68 #end if
|
|
69
|
|
70 #for $expression in $expressions:
|
|
71 -p '--expression "${expression.expression}"'
|
|
72 #end for
|
|
73
|
|
74 #include source=$standard_gatk_options#
|
|
75
|
|
76 -p '
|
|
77 #if str( $annotation_group ) != "None":
|
|
78 #for $group in str( $annotation_group ).split( ',' ):
|
|
79 --group "${group}"
|
|
80 #end for
|
|
81 #end if
|
|
82 #if str( $family_string ) != "":
|
|
83 --family_string "${family_string}"
|
|
84 #end if
|
|
85 --MendelViolationGenotypeQualityThreshold "${mendel_violation_genotype_quality_threshold}"
|
|
86 '
|
|
87 </command>
|
|
88 <inputs>
|
|
89 <conditional name="reference_source">
|
|
90 <expand macro="reference_source_selector_param" />
|
|
91 <when value="cached">
|
|
92 <param name="input_variant" type="data" format="vcf" label="Variant file to annotate" help="-V,--variant &lt;variant&gt;"/>
|
|
93 <param name="input_variant_bti" type="boolean" truevalue="-BTI variant" falsevalue="" label="Increase efficiency for small variant files." help="-BTI variant"/>
|
|
94 <param name="input_bam" type="data" format="bam" label="BAM file" optional="True" help="Not needed for all annotations. (-I,--input_file &lt;input_file&gt;)" >
|
|
95 <validator type="unspecified_build" />
|
|
96 <validator type="dataset_metadata_in_data_table" table_name="gatk2_picard_indexes" metadata_name="dbkey" metadata_column="dbkey" message="Sequences are not currently available for the specified build." /> <!-- fixme!!! this needs to be a select -->
|
|
97 </param>
|
|
98 <param name="ref_file" type="select" label="Using reference genome" help="-R,--reference_sequence &lt;reference_sequence&gt;">
|
|
99 <options from_data_table="gatk2_picard_indexes">
|
|
100 <filter type="data_meta" key="dbkey" ref="input_variant" column="dbkey"/>
|
|
101 </options>
|
|
102 <validator type="no_options" message="A built-in reference genome is not available for the build associated with the selected input file"/>
|
|
103 </param>
|
|
104 </when>
|
|
105 <when value="history"> <!-- FIX ME!!!! -->
|
|
106 <param name="input_variant" type="data" format="vcf" label="Variant file to annotate" help="-V,--variant &lt;variant&gt;"/>
|
|
107 <param name="input_variant_bti" type="boolean" truevalue="-BTI variant" falsevalue="" label="Increase efficiency for small variant files." help="-BTI variant"/>
|
|
108 <param name="input_bam" type="data" format="bam" label="BAM file" optional="True" help="Not needed for all annotations. (-I,--input_file &lt;input_file&gt;)" />
|
|
109 <param name="ref_file" type="data" format="fasta" label="Using reference file" help="-R,--reference_sequence &lt;reference_sequence&gt;" />
|
|
110 </when>
|
|
111 </conditional>
|
|
112 <conditional name="annotations_type">
|
|
113 <param name="annotations_type_selector" type="select" label="Use all possible annotations">
|
|
114 <option value="use_all_annotations">Use all</option>
|
|
115 <option value="choose" selected="True">Use selected</option>
|
|
116 </param>
|
|
117 <when value="use_all_annotations">
|
|
118 <!-- no extra options here -->
|
|
119 </when>
|
|
120 <when value="choose">
|
|
121 <param name="annotations" type="select" multiple="True" display="checkboxes" label="Annotations to apply" help="-A,--annotation &lt;annotation&gt;" >
|
|
122 <!-- load the available annotations from an external configuration file, since additional ones can be added to local installs -->
|
|
123 <options from_data_table="gatk2_annotations">
|
|
124 <filter type="multiple_splitter" column="tools_valid_for" separator=","/>
|
|
125 <filter type="static_value" value="VariantAnnotator" column="tools_valid_for"/>
|
|
126 </options>
|
|
127 </param>
|
|
128 </when>
|
|
129 </conditional>
|
|
130
|
|
131 <repeat name="additional_annotations" title="Additional annotation" help="-A,--annotation &lt;annotation&gt;">
|
|
132 <param name="additional_annotation_name" type="text" value="" label="Annotation name" />
|
|
133 </repeat>
|
|
134
|
|
135 <repeat name="comp_rod_bind" title="Binding for reference-ordered comparison data" help="-comp,--comp &lt;comp&gt;">
|
|
136 <param name="comp_input_rod" type="data" format="vcf" label="ROD file" />
|
|
137 <param name="comp_rod_name" type="text" value="Unnamed" label="ROD Name"/>
|
|
138 </repeat>
|
|
139
|
|
140 <conditional name="dbsnp_rod_bind_type">
|
|
141 <param name="dbsnp_rod_bind_type_selector" type="select" label="Provide a dbSNP reference-ordered data file" help="-D,--dbsnp &lt;dbsnp&gt;">
|
|
142 <option value="set_dbsnp" selected="True">Set dbSNP</option>
|
|
143 <option value="exclude_dbsnp">Don't set dbSNP</option>
|
|
144 </param>
|
|
145 <when value="exclude_dbsnp">
|
|
146 <!-- Do nothing here -->
|
|
147 </when>
|
|
148 <when value="set_dbsnp">
|
|
149 <param name="dbsnp_input_rod" type="data" format="vcf" label="ROD file" />
|
|
150 <param name="dbsnp_rod_name" type="hidden" value="dbsnp" label="ROD Name"/>
|
|
151 </when>
|
|
152 </conditional>
|
|
153
|
|
154 <repeat name="resource_rod_bind" title="Binding for reference-ordered resource data" help="-resource,--resource &lt;resource&gt;">
|
|
155 <param name="resource_input_rod" type="data" format="vcf" label="ROD file" />
|
|
156 <param name="resource_rod_name" type="text" value="Unnamed" label="ROD Name"/>
|
|
157 </repeat>
|
|
158
|
|
159 <conditional name="snpEff_rod_bind_type">
|
|
160 <param name="snpEff_rod_bind_type_selector" type="select" label="Provide a snpEff reference-ordered data file (VCF)" help="-snpEffFile,--snpEffFile &lt;snpEffFile&gt;">
|
|
161 <option value="set_snpEff">Set snpEff</option>
|
|
162 <option value="exclude_snpEff" selected="True">Don't set snpEff</option>
|
|
163 </param>
|
|
164 <when value="exclude_snpEff">
|
|
165 <!-- Do nothing here -->
|
|
166 </when>
|
|
167 <when value="set_snpEff">
|
|
168 <param name="snpEff_input_rod" type="data" format="vcf" label="ROD file" />
|
|
169 <param name="snpEff_rod_name" type="hidden" value="snpEff" label="ROD Name"/>
|
|
170 </when>
|
|
171 </conditional>
|
|
172
|
|
173 <repeat name="expressions" title="Expression" help="-E,--expression &lt;expression&gt;">
|
|
174 <param name="expression" type="text" value="" label="Expression"/>
|
|
175 </repeat>
|
|
176
|
|
177 <expand macro="gatk_param_type_conditional" />
|
|
178
|
|
179 <param name="annotation_group" type="select" multiple="True" display="checkboxes" label="annotation interfaces/groups to apply to variant calls" help="-G,--group &lt;group&gt;">
|
|
180 <option value="RodRequiringAnnotation">RodRequiringAnnotation</option>
|
|
181 <option value="Standard">Standard</option>
|
|
182 <option value="Experimental">Experimental</option>
|
|
183 <option value="WorkInProgress">WorkInProgress</option>
|
|
184 <option value="RankSumTest">RankSumTest</option>
|
|
185 </param>
|
|
186 <param name="family_string" type="text" value="" label="Family String" help="--family_string"/>
|
|
187 <param name="mendel_violation_genotype_quality_threshold" type="float" value="0.0" label="genotype quality treshold in order to annotate mendelian violation ratio." help="-mvq,--MendelViolationGenotypeQualityThreshold &lt;MendelViolationGenotypeQualityThreshold&gt;"/>
|
|
188 <param name="exclude_annotations" type="select" multiple="True" display="checkboxes" label="Annotations to exclude" help="-XA,--excludeAnnotation &lt;excludeAnnotation&gt;" >
|
|
189 <!-- load the available annotations from an external configuration file, since additional ones can be added to local installs -->
|
|
190 <options from_data_table="gatk2_annotations">
|
|
191 <filter type="multiple_splitter" column="tools_valid_for" separator=","/>
|
|
192 <filter type="static_value" value="VariantAnnotator" column="tools_valid_for"/>
|
|
193 </options>
|
|
194 </param>
|
|
195
|
|
196 </inputs>
|
|
197 <outputs>
|
|
198 <data format="vcf" name="output_vcf" label="${tool.name} on ${on_string} (Variant File)" />
|
|
199 <data format="txt" name="output_log" label="${tool.name} on ${on_string} (log)" />
|
|
200 </outputs>
|
|
201 <tests>
|
|
202 <test>
|
|
203 <param name="reference_source_selector" value="history" />
|
|
204 <param name="ref_file" value="phiX.fasta" ftype="fasta" />
|
|
205 <param name="input_bam" value="gatk/gatk_table_recalibration/gatk_table_recalibration_out_1.bam" ftype="bam" />
|
|
206 <param name="input_variant" value="gatk/gatk_unified_genotyper/gatk_unified_genotyper_out_1.vcf" ftype="vcf" />
|
|
207 <param name="input_variant_bti" />
|
|
208 <param name="annotations_type_selector" value="choose" />
|
|
209 <param name="annotations" value="AlleleBalance,BaseQualityRankSumTest,DepthOfCoverage,HomopolymerRun,MappingQualityRankSumTest,MappingQualityZero,QualByDepth,RMSMappingQuality,SpanningDeletions,HaplotypeScore" />
|
|
210 <param name="additional_annotations" value="0" />
|
|
211 <param name="dbsnp_rod_bind_type_selector" value="set_dbsnp" />
|
|
212 <param name="dbsnp_input_rod" value="gatk/fake_phiX_variant_locations.vcf" ftype="vcf" />
|
|
213 <param name="snpEff_rod_bind_type_selector" value="exclude_snpEff" />
|
|
214 <param name="gatk_param_type_selector" value="basic" />
|
|
215 <output name="output_vcf" file="gatk/gatk_variant_annotator/gatk_variant_annotator_out_1.vcf" lines_diff="4" />
|
|
216 <output name="output_log" file="gatk/gatk_variant_annotator/gatk_variant_annotator_out_1.log.contains" compare="contains" />
|
|
217 <param name="comp_rod_bind" value="0" />
|
|
218 <param name="resource_rod_bind" value="0" />
|
|
219 <param name="expressions" value="0" />
|
|
220 <!-- <param name="annotation_group" /> -->
|
|
221 </test>
|
|
222 </tests>
|
|
223 <help>
|
|
224 **What it does**
|
|
225
|
|
226 Annotates variant calls with context information. Users can specify which of the available annotations to use.
|
|
227
|
|
228 For more information on using the VariantAnnotator, see this `tool specific page <http://www.broadinstitute.org/gatk/gatkdocs/org_broadinstitute_sting_gatk_walkers_annotator_VariantAnnotator.html>`_.
|
|
229
|
|
230 To learn about best practices for variant detection using GATK, see this `overview <http://www.broadinstitute.org/gatk/guide/topic?name=best-practices>`_.
|
|
231
|
|
232 If you encounter errors, please view the `GATK FAQ <http://www.broadinstitute.org/gatk/guide/topic?name=faqs>`_.
|
|
233
|
|
234 ------
|
|
235
|
|
236
|
|
237 **Inputs**
|
|
238
|
|
239 GenomeAnalysisTK: VariantAnnotator accepts a variant input file.
|
|
240
|
|
241
|
|
242 **Outputs**
|
|
243
|
|
244 The output is in VCF format.
|
|
245
|
|
246
|
|
247 Go `here <http://www.broadinstitute.org/gatk/guide/topic?name=intro>`_ for details on GATK file formats.
|
|
248
|
|
249 -------
|
|
250
|
|
251 **Settings**::
|
|
252
|
|
253
|
|
254 sampleName The sample (NA-ID) corresponding to the variant input (for non-VCF input only)
|
|
255 annotation One or more specific annotations to apply to variant calls
|
|
256 group One or more classes/groups of annotations to apply to variant calls
|
|
257 expression One or more specific expressions to apply to variant calls; see documentation for more details
|
|
258 useAllAnnotations Use all possible annotations (not for the faint of heart)
|
|
259
|
|
260 @CITATION_SECTION@
|
|
261 </help>
|
|
262 </tool>
|