-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathmutect2_variant_calling.wdl
executable file
·59 lines (49 loc) · 1.26 KB
/
mutect2_variant_calling.wdl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
#WDL somatic variant calling using Mutect2 from GATK
#Tumor only
workflow mutect_variant_calling{
File BAM_LIST
Array[File] BAM_FILE_LIST = read_lines(BAM_LIST)
File SCATTER_CALLING_INTERVALS_LIST
Array[File] scatter_intervals = read_lines(SCATTER_CALLING_INTERVALS_LIST)
File samtools
File gatk
File refFasta
File refIndex
File refDict
scatter (interval in scatter_intervals){
call MuTect2{
input:
gatk = gatk,
refFasta = refFasta,
refIndex = refIndex,
refDict = refDict,
samtools = samtools,
interval_list = interval,
recal_bam = BAM_FILE_LIST
}
}
}
task MuTect2{
File gatk
File refFasta
File refIndex
File refDict
File interval_list
File samtools
Array[File] recal_bam
command {
for file in ${sep=' ' recal_bam}; do
${samtools} index -@ 2 $file
filename=$(basename $file)
output_filename=$(echo "$filename" | cut -f 1 -d '_')
java -jar ${gatk} Mutect2 \
-I $file \
-R ${refFasta} \
-L ${interval_list} \
-tumor $output_filename \
-O $output_filename".vcf"
done
}
output {
}
}