0
|
1 <tool id="gatk2_haplotype_caller" name="Haplotype Caller" version="0.0.7">
|
|
2 <description>Call SNPs and indels simultaneously via local de-novo assembly of haplotypes in an active region</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 -d "-I" "${reference_source.input_bam}" "${reference_source.input_bam.ext}" "gatk_input"
|
|
11 #if str( $reference_source.input_bam.metadata.bam_index ) != "None":
|
|
12 -d "" "${reference_source.input_bam.metadata.bam_index}" "bam_index" "gatk_input" ##hardcode galaxy ext type as bam_index
|
|
13 #end if
|
|
14 -p '
|
|
15 @JAR_PATH@
|
|
16 -T "HaplotypeCaller"
|
|
17 -o "${output_vcf}"
|
|
18
|
|
19 \$GATK2_SITE_OPTIONS
|
|
20
|
|
21 @THREADS@
|
|
22
|
|
23 #if $reference_source.reference_source_selector != "history":
|
|
24 -R "${reference_source.ref_file.fields.path}"
|
|
25 #end if
|
|
26 #if str($input_recal) != 'None':
|
|
27 --BQSR "${input_recal}"
|
|
28 #end if
|
|
29 '
|
|
30 #include source=$standard_gatk_options#
|
|
31
|
|
32 ##start analysis specific options
|
|
33 #if $analysis_param_type.analysis_param_type_selector == "advanced":
|
|
34 -p '
|
|
35 #if $analysis_param_type.p_nonref_model.__str__ != "None" and len($analysis_param_type.p_nonref_model.__str__) > 0:
|
|
36 --p_nonref_model $analysis_param_type.p_nonref_model
|
|
37 #end if
|
|
38 #if $analysis_param_type.heterozygosity.__str__.strip() != '':
|
|
39 --heterozygosity $analysis_param_type.heterozygosity
|
|
40 #end if
|
|
41 --genotyping_mode "${analysis_param_type.genotyping_mode_type.genotyping_mode}"
|
|
42 #if str( $analysis_param_type.genotyping_mode_type.genotyping_mode ) == 'GENOTYPE_GIVEN_ALLELES':
|
|
43 --alleles "${analysis_param_type.genotyping_mode_type.input_alleles_rod}"
|
|
44 #end if
|
|
45 #if $analysis_param_type.output_mode.__str__ != "None" and len($analysis_param_type.output_mode.__str__) > 0:
|
|
46 --output_mode $analysis_param_type.output_mode
|
|
47 #end if
|
|
48
|
|
49 ## files
|
|
50 #if str($analysis_param_type.activeRegionIn) != 'None':
|
|
51 --activeRegionIn "$analysis_param_type.activeRegionIn"
|
|
52 #end if
|
|
53 #if str($analysis_param_type.comp) != 'None':
|
|
54 --comp "$analysis_param_type.comp"
|
|
55 #end if
|
|
56 #if str($analysis_param_type.dbsnp) != 'None':
|
|
57 --dbsnp "$analysis_param_type.dbsnp"
|
|
58 #end if
|
|
59 ##
|
|
60 #if str( $analysis_param_type.annotation ) != "None":
|
|
61 #for $annotation in str( $analysis_param_type.annotation.fields.gatk_value ).split( ','):
|
|
62 --annotation "${annotation}"
|
|
63 #end for
|
|
64 #end if
|
|
65 #for $additional_annotation in $analysis_param_type.additional_annotations:
|
|
66 --annotation "${additional_annotation.additional_annotation_name}"
|
|
67 #end for
|
|
68 #if str( $analysis_param_type.group ) != "None":
|
|
69 #for $group in str( $analysis_param_type.group ).split( ','):
|
|
70 --group "${group}"
|
|
71 #end for
|
|
72 #end if
|
|
73 #if str( $analysis_param_type.exclude_annotations ) != "None":
|
|
74 #for $annotation in str( $analysis_param_type.exclude_annotations.fields.gatk_value ).split( ','):
|
|
75 --excludeAnnotation "${annotation}"
|
|
76 #end for
|
|
77 #end if
|
|
78
|
|
79 ## value setings
|
|
80 #if $analysis_param_type.contamination_fraction_to_filter.__str__.strip() != '':
|
|
81 --contamination_fraction_to_filter $analysis_param_type.contamination_fraction_to_filter
|
|
82 #end if
|
|
83 #if $analysis_param_type.downsampleRegion.__str__.strip() != '':
|
|
84 --downsampleRegion $analysis_param_type.downsampleRegion
|
|
85 #end if
|
|
86 #if $analysis_param_type.minPruning.__str__.strip() != '':
|
|
87 --minPruning $analysis_param_type.minPruning
|
|
88 #end if
|
|
89 #if $analysis_param_type.standard_min_confidence_threshold_for_calling.__str__.strip() != '':
|
|
90 --standard_min_confidence_threshold_for_calling $analysis_param_type.standard_min_confidence_threshold_for_calling
|
|
91 #end if
|
|
92 #if $analysis_param_type.standard_min_confidence_threshold_for_emitting.__str__.strip() != '':
|
|
93 --standard_min_confidence_threshold_for_emitting $analysis_param_type.standard_min_confidence_threshold_for_emitting
|
|
94 #end if
|
|
95 #if $analysis_param_type.gcpHMM.__str__.strip() != '':
|
|
96 --gcpHMM $analysis_param_type.gcpHMM
|
|
97 #end if
|
|
98 #if $analysis_param_type.max_alternate_alleles.__str__.strip() != '':
|
|
99 --max_alternate_alleles $analysis_param_type.max_alternate_alleles
|
|
100 #end if
|
|
101 ## mode selections
|
|
102 #if $analysis_param_type.genotyping_mode.__str__ != "None" and len($analysis_param_type.genotyping_mode.__str__) > 0:
|
|
103 --genotyping_mode $analysis_param_type.genotyping_mode
|
|
104 #end if
|
|
105 #if $analysis_param_type.pair_hmm_implementation.__str__ != "None" and len($analysis_param_type.pair_hmm_implementation.__str__) > 0:
|
|
106 --pair_hmm_implementation $analysis_param_type.pair_hmm_implementation
|
|
107 #end if
|
|
108 ## optional outputs
|
|
109 #if $analysis_param_type.activeRegionOut:
|
|
110 --activeRegionOut $active_region_out
|
|
111 #end if
|
|
112 #if $analysis_param_type.graphOutput:
|
|
113 --graphOutput $graph_out
|
|
114 #end if
|
|
115 ## flags
|
|
116 $analysis_param_type.useAllelesTrigger
|
|
117 $analysis_param_type.fullHaplotype
|
|
118 $analysis_param_type.genotypeFullActiveRegion
|
|
119 $analysis_param_type.debug
|
|
120 '
|
|
121 #end if
|
|
122 </command>
|
|
123 <inputs>
|
|
124 <param name="input_recal" type="data" format="gatk_report" optional="true" label="Covariates table recalibration file" help="-BQSR,--BQSR &lt;recal_file&gt;" >
|
|
125 <help>The input covariates table file which enables on-the-fly base quality score recalibration.
|
|
126 Enables on-the-fly recalibrate of base qualities. The covariates tables are produced by the BaseQualityScoreRecalibrator tool.
|
|
127 Please be aware that one should only run recalibration with the covariates file created on the same input bam(s).
|
|
128 </help>
|
|
129 </param>
|
|
130 <conditional name="reference_source">
|
|
131 <expand macro="reference_source_selector_param" />
|
|
132 <when value="cached">
|
|
133 <param name="input_bam" type="data" format="bam" label="BAM file" help="-I,--input_file &lt;input_file&gt;">
|
|
134 <validator type="unspecified_build" />
|
|
135 <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 -->
|
|
136 </param>
|
|
137 <param name="ref_file" type="select" label="Using reference genome" help="-R,--reference_sequence &lt;reference_sequence&gt;" >
|
|
138 <options from_data_table="gatk2_picard_indexes">
|
|
139 <filter type="data_meta" key="dbkey" ref="input_bam" column="dbkey"/>
|
|
140 </options>
|
|
141 <validator type="no_options" message="A built-in reference genome is not available for the build associated with the selected input file"/>
|
|
142 </param>
|
|
143 </when>
|
|
144 <when value="history">
|
|
145 <param name="input_bam" type="data" format="bam" label="BAM file" help="-I,--input_file &lt;input_file&gt;" />
|
|
146 <param name="ref_file" type="data" format="fasta" label="Using reference file" help="-R,--reference_sequence &lt;reference_sequence&gt;">
|
|
147 <options>
|
|
148 <filter type="data_meta" key="dbkey" ref="input_bam" />
|
|
149 </options>
|
|
150 </param>
|
|
151 </when>
|
|
152 </conditional>
|
|
153
|
|
154 <expand macro="gatk_param_type_conditional" />
|
|
155
|
|
156 <conditional name="analysis_param_type">
|
|
157 <param name="analysis_param_type_selector" type="select" label="Basic or Advanced Analysis options">
|
|
158 <option value="basic" selected="True">Basic</option>
|
|
159 <option value="advanced">Advanced</option>
|
|
160 </param>
|
|
161 <when value="basic">
|
|
162 <!-- Do nothing here -->
|
|
163 </when>
|
|
164 <when value="advanced">
|
|
165
|
|
166 <param name="activeRegionIn" type="data" format="bed,gatk_interval,picard_interval_list,vcf" optional="true" label="activeRegionIn" help="--activeRegionIn / -AR Use this interval list file as the active regions to process"/>
|
|
167 <param name="activeRegionOut" type="boolean" checked="False" truevalue="" falsevalue="" label="activeRegionOut" help="--activeRegionOut / -ARO Output the active region to an interval list file"/>
|
|
168
|
|
169 <param name="annotation" type="select" multiple="True" display="checkboxes" label="Annotation Types" help="-A,--annotation &lt;annotation&gt;">
|
|
170 <!-- load the available annotations from an external configuration file, since additional ones can be added to local installs -->
|
|
171 <options from_data_table="gatk2_annotations">
|
|
172 <filter type="multiple_splitter" column="tools_valid_for" separator=","/>
|
|
173 <filter type="static_value" value="UnifiedGenotyper" column="tools_valid_for"/>
|
|
174 </options>
|
|
175 </param>
|
|
176 <repeat name="additional_annotations" title="Additional annotation" help="-A,--annotation &lt;annotation&gt;">
|
|
177 <param name="additional_annotation_name" type="text" value="" label="Annotation name" />
|
|
178 </repeat>
|
|
179 <!--
|
|
180 <conditional name="snpEff_rod_bind_type">
|
|
181 <param name="snpEff_rod_bind_type_selector" type="select" label="Provide a snpEff reference-ordered data file">
|
|
182 <option value="set_snpEff">Set snpEff</option>
|
|
183 <option value="exclude_snpEff" selected="True">Don't set snpEff</option>
|
|
184 </param>
|
|
185 <when value="exclude_snpEff">
|
|
186 </when>
|
|
187 <when value="set_snpEff">
|
|
188 <param name="snpEff_input_rod" type="data" format="vcf" label="ROD file" />
|
|
189 <param name="snpEff_rod_name" type="hidden" value="snpEff" label="ROD Name"/>
|
|
190 </when>
|
|
191 </conditional>
|
|
192 -->
|
|
193 <param name="group" type="select" multiple="True" display="checkboxes" label="Annotation Interfaces/Groups" help="-G,--group &lt;group&gt;">
|
|
194 <option value="RodRequiringAnnotation">RodRequiringAnnotation</option>
|
|
195 <option value="Standard">Standard</option>
|
|
196 <option value="Experimental">Experimental</option>
|
|
197 <option value="WorkInProgress">WorkInProgress</option>
|
|
198 <option value="RankSumTest">RankSumTest</option>
|
|
199 <!-- <option value="none">none</option> -->
|
|
200 </param>
|
|
201 <!-- <param name="family_string" type="text" value="" label="Family String"/> -->
|
|
202 <param name="exclude_annotations" type="select" multiple="True" display="checkboxes" label="Annotations to exclude" help="-XA,--excludeAnnotation &lt;excludeAnnotation&gt;" >
|
|
203 <!-- load the available annotations from an external configuration file, since additional ones can be added to local installs -->
|
|
204 <options from_data_table="gatk2_annotations">
|
|
205 <filter type="multiple_splitter" column="tools_valid_for" separator=","/>
|
|
206 <filter type="static_value" value="UnifiedGenotyper" column="tools_valid_for"/>
|
|
207 </options>
|
|
208 </param>
|
|
209
|
|
210 <param name="comp" type="data" format="vcf" optional="true" label="comp" help="--comp / -comp comparison VCF file"/>
|
|
211 <param name="contamination_fraction_to_filter" type="float" value="0.05" optional="true" label="contamination_fraction_to_filter" help="--contamination_fraction_to_filter / -contamination Fraction of contamination in sequencing data (for all samples) to aggressively remove">
|
|
212 <validator type="in_range" message="value between 0.00 and 1.00" min="0" max="1"/>
|
|
213 </param>
|
|
214 <param name="dbsnp" type="data" format="vcf" optional="true" label="dbsnp" help="--dbsnp / -D dbSNP file"/>
|
|
215 <param name="debug" type="boolean" checked="False" truevalue="-debug" falsevalue="" label="debug" help="--debug / -debug If specified, print out very verbose debug information about each triggering active region"/>
|
|
216 <param name="downsampleRegion" type="integer" value="1000" optional="true" label="downsampleRegion" help="--downsampleRegion / -dr coverage, per-sample, to downsample each active region to"/>
|
|
217
|
|
218 <conditional name="genotyping_mode_type">
|
|
219 <param name="genotyping_mode" type="select" label="How to determine the alternate allele to use for genotyping" help="-gt_mode,--genotyping_mode &lt;genotyping_mode&gt;">
|
|
220 <option value="DISCOVERY" selected="True">DISCOVERY</option>
|
|
221 <option value="GENOTYPE_GIVEN_ALLELES">GENOTYPE_GIVEN_ALLELES</option>
|
|
222 </param>
|
|
223 <when value="DISCOVERY">
|
|
224 <!-- Do nothing here -->
|
|
225 </when>
|
|
226 <when value="GENOTYPE_GIVEN_ALLELES">
|
|
227 <param name="input_alleles_rod" type="data" format="vcf" label="Alleles ROD file" help="-alleles,--alleles &lt;alleles&gt;" />
|
|
228 </when>
|
|
229 </conditional>
|
|
230
|
|
231
|
|
232 <param name="graphOutput" type="boolean" checked="False" truevalue="" falsevalue="" label="graphOutput" help="--graphOutput / -graph File to which debug assembly graph information should be written"/>
|
|
233 <param name="heterozygosity" type="float" value="0.0010" optional="true" label="heterozygosity" help="--heterozygosity / -hets Heterozygosity value used to compute prior likelihoods for any locus"/>
|
|
234 <param name="minPruning" type="integer" value="1" optional="true" label="minPruning" help="--minPruning / -minPruning The minimum allowed pruning factor in assembly graph. Paths with >= X supporting kmers are pruned from the graph">
|
|
235 <validator type="in_range" message="value between 0 and 127" min="0" max="127"/>
|
|
236 </param>
|
|
237 <param name="output_mode" type="select" optional="true" label="output_mode" help="--output_mode / -out_mode Specifies which type of calls we should output">
|
|
238 <option value="EMIT_VARIANTS_ONLY" selected="True">EMIT_VARIANTS_ONLY</option>
|
|
239 <option value="EMIT_ALL_CONFIDENT_SITES">EMIT_ALL_CONFIDENT_SITES</option>
|
|
240 <option value="EMIT_ALL_SITES">EMIT_ALL_SITES</option>
|
|
241 </param>
|
|
242 <param name="pair_hmm_implementation" type="select" optional="true" label="pair_hmm_implementation" help="--pair_hmm_implementation / -pairHMM The PairHMM implementation to use for genotype likelihood calculations">
|
|
243 <option value="EXACT">EXACT</option>
|
|
244 <option value="ORIGINAL">ORIGINAL</option>
|
|
245 <option value="CACHING">CACHING</option>
|
|
246 <option value="LOGLESS_CACHING" selected="True">LOGLESS_CACHING</option>
|
|
247 </param>
|
|
248 <param name="standard_min_confidence_threshold_for_calling" type="float" value="30.0" optional="true" label="standard_min_confidence_threshold_for_calling" help="--standard_min_confidence_threshold_for_calling / -stand_call_conf The minimum phred-scaled confidence threshold at which variants should be called"/>
|
|
249 <param name="standard_min_confidence_threshold_for_emitting" type="float" value="30.0" optional="true" label="standard_min_confidence_threshold_for_emitting" help="--standard_min_confidence_threshold_for_emitting / -stand_emit_conf The minimum phred-scaled confidence threshold at which variants should be emitted (and filtered with LowQual if less than the calling threshold)"/>
|
|
250 <param name="useAllelesTrigger" type="boolean" checked="False" truevalue="-allelesTrigger" falsevalue="" label="useAllelesTrigger" help="--useAllelesTrigger / -allelesTrigger If specified, use additional trigger on variants found in an external alleles file"/>
|
|
251 <param name="fullHaplotype" type="boolean" checked="False" truevalue="-fullHaplotype" falsevalue="" label="fullHaplotype" help="--fullHaplotype / -fullHaplotype If specified, output the full haplotype sequence instead of converting to individual variants w.r.t. the reference"/>
|
|
252 <param name="gcpHMM" type="integer" value="10" optional="true" label="gcpHMM" help="--gcpHMM / -gcpHMM Flat gap continuation penalty for use in the Pair HMM"/>
|
|
253 <param name="genotypeFullActiveRegion" type="boolean" checked="False" truevalue="-genotypeFullActiveRegion" falsevalue="" label="genotypeFullActiveRegion" help="--genotypeFullActiveRegion / -genotypeFullActiveRegion If specified, alternate alleles are considered to be the full active region for the purposes of genotyping"/>
|
|
254 <param name="max_alternate_alleles" type="integer" value="6" optional="true" label="max_alternate_alleles" help="--max_alternate_alleles / -maxAltAlleles Maximum number of alternate alleles to genotype"/>
|
|
255 <param name="p_nonref_model" type="select" optional="true" label="p_nonref_model" help="--p_nonref_model / -pnrm Non-reference probability calculation model to employ">
|
|
256 <option value="EXACT_INDEPENDENT" selected="True">EXACT_INDEPENDENT experimental implementation - for testing only</option>
|
|
257 <option value="EXACT_REFERENCE">EXACT_REFERENCE reference implementation of multi-allelic EXACT model. Extremely slow for many alternate alleles</option>
|
|
258 <option value="EXACT_ORIGINAL">EXACT_ORIGINAL original biallelic exact model, for testing only</option>
|
|
259 <option value="EXACT_GENERAL_PLOIDY">implementation that supports any sample ploidy</option>
|
|
260 </param>
|
|
261
|
|
262 </when>
|
|
263 </conditional>
|
|
264 </inputs>
|
|
265 <outputs>
|
|
266 <data format="vcf" name="output_vcf" label="${tool.name} on ${on_string} (VCF)" />
|
|
267 <data format="vcf" name="graph_out" label="${tool.name} on ${on_string} graph" >
|
|
268 <filter>analysis_param_type['analysis_param_type_selector'] == "advanced" and analysis_param_type['graphOutput'] == True</filter>
|
|
269 </data>
|
|
270 <data format="vcf" name="active_region_out" label="${tool.name} on ${on_string} activeRegion" >
|
|
271 <filter>analysis_param_type['analysis_param_type_selector'] == "advanced" and analysis_param_type['activeRegionOut'] == True</filter>
|
|
272 </data>
|
|
273 <data format="txt" name="output_log" label="${tool.name} on ${on_string} (log)" />
|
|
274 </outputs>
|
|
275 <tests>
|
|
276 <test>
|
|
277 <param name="input_recal" value="gatk/gatk_count_covariates/gatk_count_covariates_out_1.csv" ftype="csv" />
|
|
278 <param name="reference_source_selector" value="history" />
|
|
279 <param name="ref_file" value="phiX.fasta" ftype="fasta" />
|
|
280 <param name="input_bam" value="gatk/gatk_indel_realigner/gatk_indel_realigner_out_1.bam" ftype="bam" />
|
|
281 <param name="gatk_param_type_selector" value="basic" />
|
|
282 <param name="analysis_param_type_selector" value="basic" />
|
|
283 <output name="output_bam" file="gatk/gatk_table_recalibration/gatk_table_recalibration_out_1.bam" ftype="bam" lines_diff="4" />
|
|
284 <output name="output_log" file="gatk/gatk_table_recalibration/gatk_table_recalibration_out_1.log.contains" compare="contains" />
|
|
285 </test>
|
|
286 </tests>
|
|
287 <help>
|
|
288 **What it does**
|
|
289
|
|
290 **HaplotypeCaller**
|
|
291 calls SNPs and indels simultaneously via local de-novo assembly of haplotypes in an active region.
|
|
292 Haplotypes are evaluated using an affine gap penalty Pair HMM.
|
|
293
|
|
294 For more information on using read based compression in the GATK, see this `tool specific page <http://www.broadinstitute.org/gatk/gatkdocs/org_broadinstitute_sting_gatk_walkers_haplotypecaller_HaplotypeCaller.html>`_.
|
|
295
|
|
296 To learn about best practices for variant detection using GATK, see this `overview <http://www.broadinstitute.org/gatk/guide/topic?name=best-practices>`_.
|
|
297
|
|
298 If you encounter errors, please view the `GATK FAQ <http://www.broadinstitute.org/gatk/guide/topic?name=faqs>`_.
|
|
299
|
|
300 ------
|
|
301
|
|
302 **Inputs**
|
|
303
|
|
304 GenomeAnalysisTK: PrintReads accepts aligned BAM files.
|
|
305
|
|
306
|
|
307 **Outputs**
|
|
308
|
|
309 The output is a VCF file with raw, unrecalibrated SNP and indel calls.
|
|
310
|
|
311
|
|
312 Go `here <http://www.broadinstitute.org/gatk/guide/topic?name=intro>`_ for details on GATK file formats.
|
|
313
|
|
314 -------
|
|
315
|
|
316 **Settings**::
|
|
317
|
|
318 activeRegionIn Use this interval list file as the active regions to process
|
|
319 activeRegionOut Output the active region to this interval list file
|
|
320 alleles The set of alleles at which to genotype when --genotyping_mode is GENOTYPE_GIVEN_ALLELES
|
|
321 annotation One or more specific annotations to apply to variant calls
|
|
322 comp comparison VCF file
|
|
323 contamination Fraction of contamination in sequencing data (for all samples) to aggressively remove
|
|
324 dbsnp dbSNP file
|
|
325 debug If specified, print out very verbose debug information about each triggering active region
|
|
326 downsampleRegion coverage, per-sample, to downsample each active region to
|
|
327 excludeAnnotation One or more specific annotations to exclude
|
|
328 genotyping_mode Specifies how to determine the alternate alleles to use for genotyping
|
|
329 graphOutput File to which debug assembly graph information should be written
|
|
330 group One or more classes/groups of annotations to apply to variant calls
|
|
331 heterozygosity Heterozygosity value used to compute prior likelihoods for any locus
|
|
332 minPruning The minimum allowed pruning factor in assembly graph. Paths with less than or equal supporting kmers are pruned from the graph
|
|
333 output_mode Specifies which type of calls we should output
|
|
334 pair_hmm_implementation The PairHMM implementation to use for genotype likelihood calculations
|
|
335 stand_call_conf The minimum phred-scaled confidence threshold at which variants should be called
|
|
336 stand_emit_conf The minimum phred-scaled confidence threshold at which variants should be emitted (and filtered with LowQual if less than the calling threshold)
|
|
337 useAllelesTrigger If specified, use additional trigger on variants found in an external alleles file
|
|
338 fullHaplotype If specified, output the full haplotype sequence instead of converting to individual variants w.r.t. the reference
|
|
339 gcpHMM Flat gap continuation penalty for use in the Pair HMM
|
|
340 genotypeFullActiveRegion If specified, alternate alleles are considered to be the full active region for the purposes of genotyping
|
|
341 max_alternate_alleles Maximum number of alternate alleles to genotype
|
|
342 p_nonref_model Non-reference probability calculation model to employ
|
|
343
|
|
344 ------
|
|
345
|
|
346 @CITATION_SECTION@
|
|
347 </help>
|
|
348 </tool>
|