-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[refs #119] Adds GATK v3.8 of MuTect2
- Loading branch information
1 parent
e7afedd
commit 2a2004a
Showing
1 changed file
with
94 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,94 @@ | ||
version 1.0 | ||
# ------------------------------------------------------------------------------------------------- | ||
# Package Name: MuTect v2, GATK v3.8.1 | ||
# Task Summary: Call somatic SNPs and indels via local re-assembly of haplotypes | ||
# Tool Name: MuTect2 | ||
# ------------------------------------------------------------------------------------------------- | ||
|
||
task MuTect2 { | ||
input { | ||
File ? java | ||
File gatk | ||
|
||
File tumor_bam | ||
File tumor_bam_idx | ||
String sample_id | ||
|
||
File ? normal_bam | ||
File ? normal_bam_idx | ||
String ? normal_sample_id | ||
|
||
Array[File] intervals = [] | ||
Array[File] germline_resources = [] | ||
|
||
File reference | ||
File reference_idx | ||
File reference_dict | ||
|
||
File ? panel_of_normals | ||
String ? userString | ||
|
||
Array[String] modules = [] | ||
Float memory = 64 | ||
Int cpu = 16 | ||
} | ||
|
||
String output_vcf_name = sample_id + '.MuTect2.vcf' | ||
Array[String] intervalOptions = prefix("--intervals ", intervals) | ||
Array[String] germline_resourceOptions = prefix("--germline-resource ", germline_resources) | ||
|
||
command { | ||
set -Eeuxo pipefail; | ||
|
||
for MODULE in ~{sep=' ' modules}; do | ||
module load $MODULE | ||
done; | ||
|
||
~{default="java" java} -jar ~{gatk} | ||
-T MuTect2 \ | ||
-R ~{reference} \ | ||
-I:tumor ~{tumor_bam} \ | ||
~{sep=" " intervalOptions} \ | ||
~{sep=" " germline_resourceOptions} \ | ||
~{"-I:normal " + normal_bam} \ | ||
~{userString} \ | ||
~{"--panel-of-normals " + panel_of_normals} \ | ||
-o ~{output_vcf_name}; | ||
} | ||
|
||
output { | ||
File vcf_file = "~{output_vcf_name}" | ||
File vcf_idx_file = "~{output_vcf_name}" + ".idx" | ||
} | ||
|
||
runtime { | ||
memory: memory * 1.5 + " GB" | ||
cpu: cpu | ||
} | ||
|
||
parameter_meta { | ||
gatk: "GATK <v4.0.0 jar file" | ||
reference: "Reference sequence file." | ||
reference_idx: "Reference sequence index (.fai)." | ||
reference_dict: "Reference sequence dict (.dict)." | ||
tumor_bam: "BAM file for tumor sample; required." | ||
sample_id: "ID for the tumor_bam." | ||
normal_bam: "BAM file for normal sample; not required" | ||
normal_sample_id: "ID for the normal sample; required if normal_bam is provided" | ||
panel_of_normals: "VCF built with MuTect2 CreateSomaticPanelOfNormals" | ||
germline_resources: "VCF of other germline events, e.g. gnomAD, dbSNP, COSMIC, etc" | ||
intervals: "One or more genomic intervals over which to operate." | ||
sample_id: "tumor sample id; prefix for output files" | ||
userString: "An optional parameter which allows the user to specify additions to the command line at run time." | ||
memory: "GB of RAM to use at runtime." | ||
cpu: "Number of CPUs to use at runtime." | ||
} | ||
|
||
meta { | ||
author: "Mark Welsh" | ||
email: "[email protected]" | ||
gatk_version: "3.8.1" | ||
version: "0.1.0" | ||
} | ||
} |