2021-09-13 11:16:23 -04:00
#!/usr/bin/env nextflow
nextflow.enable.dsl = 2
2021-11-26 02:58:40 -05:00
include { GATK4_MUTECT2 } from '../../../../modules/gatk4/mutect2/main.nf'
2021-09-13 11:16:23 -04:00
workflow test_gatk4_mutect2_tumor_normal_pair {
input = [ [ id:'test'], // meta map
2021-12-20 11:10:49 -05:00
[ file(params.test_data['homo_sapiens']['illumina']['test_paired_end_recalibrated_sorted_bam'], checkIfExists: true),
file(params.test_data['homo_sapiens']['illumina']['test2_paired_end_recalibrated_sorted_bam'], checkIfExists: true)
],
[ file(params.test_data['homo_sapiens']['illumina']['test_paired_end_recalibrated_sorted_bam_bai'], checkIfExists: true),
file(params.test_data['homo_sapiens']['illumina']['test2_paired_end_recalibrated_sorted_bam_bai'], checkIfExists: true)
],
["normal"]
2021-09-13 11:16:23 -04:00
]
run_single = false
run_pon = false
2021-10-29 06:27:56 -04:00
run_mito = false
interval_label = []
2021-12-20 11:10:49 -05:00
fasta = file(params.test_data['homo_sapiens']['genome']['genome_21_fasta'], checkIfExists: true)
fai = file(params.test_data['homo_sapiens']['genome']['genome_21_fasta_fai'], checkIfExists: true)
dict = file(params.test_data['homo_sapiens']['genome']['genome_21_dict'], checkIfExists: true)
germline_resource = file(params.test_data['homo_sapiens']['genome']['gnomad_r2_1_1_21_vcf_gz'], checkIfExists: true)
germline_resource_tbi = file(params.test_data['homo_sapiens']['genome']['gnomad_r2_1_1_21_vcf_gz_tbi'], checkIfExists: true)
panel_of_normals = file(params.test_data['homo_sapiens']['genome']['mills_and_1000g_indels_21_vcf_gz'], checkIfExists: true)
panel_of_normals_tbi = file(params.test_data['homo_sapiens']['genome']['mills_and_1000g_indels_21_vcf_gz_tbi'], checkIfExists: true)
2021-09-13 11:16:23 -04:00
2021-12-20 11:10:49 -05:00
GATK4_MUTECT2 ( input, run_single, run_pon, run_mito, interval_label, fasta, fai, dict, germline_resource, germline_resource_tbi, panel_of_normals, panel_of_normals_tbi )
2021-09-13 11:16:23 -04:00
}
workflow test_gatk4_mutect2_tumor_single {
input = [ [ id:'test'], // meta map
[ file(params.test_data['homo_sapiens']['illumina']['test2_paired_end_recalibrated_sorted_bam'], checkIfExists: true)],
[ file(params.test_data['homo_sapiens']['illumina']['test2_paired_end_recalibrated_sorted_bam_bai'], checkIfExists: true)],
[]
]
run_single = true
run_pon = false
2021-10-29 06:27:56 -04:00
run_mito = false
interval_label = []
2021-12-20 11:10:49 -05:00
fasta = file(params.test_data['homo_sapiens']['genome']['genome_21_fasta'], checkIfExists: true)
fai = file(params.test_data['homo_sapiens']['genome']['genome_21_fasta_fai'], checkIfExists: true)
dict = file(params.test_data['homo_sapiens']['genome']['genome_21_dict'], checkIfExists: true)
germline_resource = file(params.test_data['homo_sapiens']['genome']['gnomad_r2_1_1_21_vcf_gz'], checkIfExists: true)
germline_resource_tbi = file(params.test_data['homo_sapiens']['genome']['gnomad_r2_1_1_21_vcf_gz_tbi'], checkIfExists: true)
panel_of_normals = file(params.test_data['homo_sapiens']['genome']['mills_and_1000g_indels_21_vcf_gz'], checkIfExists: true)
panel_of_normals_tbi = file(params.test_data['homo_sapiens']['genome']['mills_and_1000g_indels_21_vcf_gz_tbi'], checkIfExists: true)
2021-09-13 11:16:23 -04:00
2021-11-15 12:03:02 -05:00
GATK4_MUTECT2 ( input, run_single, run_pon, run_mito, interval_label, fasta, fai, dict, germline_resource, germline_resource_tbi, panel_of_normals, panel_of_normals_tbi )
2021-10-29 06:27:56 -04:00
}
workflow test_gatk4_mutect2_cram_input {
input = [ [ id:'test'], // meta map
[ file(params.test_data['homo_sapiens']['illumina']['test2_paired_end_recalibrated_sorted_cram'], checkIfExists: true)],
[ file(params.test_data['homo_sapiens']['illumina']['test2_paired_end_recalibrated_sorted_cram_crai'], checkIfExists: true)],
[]
]
run_single = true
run_pon = false
run_mito = false
interval_label = []
2021-12-20 11:10:49 -05:00
fasta = file(params.test_data['homo_sapiens']['genome']['genome_21_fasta'], checkIfExists: true)
fai = file(params.test_data['homo_sapiens']['genome']['genome_21_fasta_fai'], checkIfExists: true)
dict = file(params.test_data['homo_sapiens']['genome']['genome_21_dict'], checkIfExists: true)
germline_resource = file(params.test_data['homo_sapiens']['genome']['gnomad_r2_1_1_21_vcf_gz'], checkIfExists: true)
germline_resource_tbi = file(params.test_data['homo_sapiens']['genome']['gnomad_r2_1_1_21_vcf_gz_tbi'], checkIfExists: true)
panel_of_normals = file(params.test_data['homo_sapiens']['genome']['mills_and_1000g_indels_21_vcf_gz'], checkIfExists: true)
panel_of_normals_tbi = file(params.test_data['homo_sapiens']['genome']['mills_and_1000g_indels_21_vcf_gz_tbi'], checkIfExists: true)
2021-10-29 06:27:56 -04:00
2021-11-15 12:03:02 -05:00
GATK4_MUTECT2 ( input, run_single, run_pon, run_mito, interval_label, fasta, fai, dict, germline_resource, germline_resource_tbi, panel_of_normals, panel_of_normals_tbi )
2021-09-13 11:16:23 -04:00
}
workflow test_gatk4_mutect2_generate_pon {
input = [ [ id:'test'], // meta map
[ file(params.test_data['homo_sapiens']['illumina']['test_paired_end_recalibrated_sorted_bam'], checkIfExists: true)],
[ file(params.test_data['homo_sapiens']['illumina']['test_paired_end_recalibrated_sorted_bam_bai'], checkIfExists: true)],
[]
]
run_single = false
run_pon = true
2021-10-29 06:27:56 -04:00
run_mito = false
interval_label = []
2021-12-20 11:10:49 -05:00
fasta = file(params.test_data['homo_sapiens']['genome']['genome_21_fasta'], checkIfExists: true)
fai = file(params.test_data['homo_sapiens']['genome']['genome_21_fasta_fai'], checkIfExists: true)
dict = file(params.test_data['homo_sapiens']['genome']['genome_21_dict'], checkIfExists: true)
2021-10-29 06:27:56 -04:00
germline_resource = []
2021-11-15 11:49:20 -05:00
germline_resource_tbi = []
2021-10-29 06:27:56 -04:00
panel_of_normals = []
2021-11-15 11:49:20 -05:00
panel_of_normals_tbi = []
2021-10-29 06:27:56 -04:00
2021-11-15 12:03:02 -05:00
GATK4_MUTECT2 ( input, run_single, run_pon, run_mito, interval_label, fasta, fai, dict, germline_resource, germline_resource_tbi, panel_of_normals, panel_of_normals_tbi )
2021-10-29 06:27:56 -04:00
}
// mitochondria mode would ideally have some mitochondria test data, but since the mitochondria settings only increase detection sensitivity, we can use the chr22 data as a stand in as it is already a small dataset, the extra variants detected compared to generate_pon shows the mode is working.
workflow test_gatk4_mutect2_mitochondria {
input = [ [ id:'test'], // meta map
2021-12-20 11:10:49 -05:00
[ file(params.test_data['homo_sapiens']['illumina']['mitochon_standin_recalibrated_sorted_bam'], checkIfExists: true)],
[ file(params.test_data['homo_sapiens']['illumina']['mitochon_standin_recalibrated_sorted_bam_bai'], checkIfExists: true)],
2021-10-29 06:27:56 -04:00
[]
]
run_single = false
run_pon = false
run_mito = true
interval_label = 'chr22'
2021-09-13 11:16:23 -04:00
fasta = file(params.test_data['homo_sapiens']['genome']['genome_fasta'], checkIfExists: true)
2021-11-15 12:03:02 -05:00
fai = file(params.test_data['homo_sapiens']['genome']['genome_fasta_fai'], checkIfExists: true)
2021-09-13 11:16:23 -04:00
dict = file(params.test_data['homo_sapiens']['genome']['genome_dict'], checkIfExists: true)
germline_resource = []
2021-11-15 11:49:20 -05:00
germline_resource_tbi = []
2021-09-13 11:16:23 -04:00
panel_of_normals = []
2021-11-15 11:49:20 -05:00
panel_of_normals_tbi = []
2021-09-13 11:16:23 -04:00
2021-11-15 12:03:02 -05:00
GATK4_MUTECT2 ( input, run_single, run_pon, run_mito, interval_label, fasta, fai, dict, germline_resource, germline_resource_tbi, panel_of_normals, panel_of_normals_tbi )
2021-09-13 11:16:23 -04:00
}