diff --git a/modules/nf-core/custom/matrixfilter/main.nf b/modules/nf-core/custom/matrixfilter/main.nf index f569fd6ca11..137918d704a 100644 --- a/modules/nf-core/custom/matrixfilter/main.nf +++ b/modules/nf-core/custom/matrixfilter/main.nf @@ -12,6 +12,7 @@ process CUSTOM_MATRIXFILTER { output: tuple val(meta), path("*.filtered.tsv") , emit: filtered + tuple val(meta), path("*.tests.tsv") , emit: tests tuple val(meta), path("R_sessionInfo.log") , emit: session_info path "versions.yml" , emit: versions diff --git a/modules/nf-core/custom/matrixfilter/meta.yml b/modules/nf-core/custom/matrixfilter/meta.yml index 337af6d6e45..9911efce09e 100644 --- a/modules/nf-core/custom/matrixfilter/meta.yml +++ b/modules/nf-core/custom/matrixfilter/meta.yml @@ -4,6 +4,8 @@ description: filter a matrix based on a minimum value and numbers of samples keywords: - matrix - filter + - abundance + - na tools: - "matrixfilter": description: "filter a matrix based on a minimum value and numbers of samples" @@ -34,32 +36,44 @@ input: present (see grouping_variable), but also to validate matrix columns. If not provided, all numeric columns are selected. - minimum_abundance: - type: numeric + type: float description: | Minimum abundance value, supplied via task.ext.args as --minimum_abundance default: 1 - minimum_samples: - type: numeric + type: integer description: | Minimum observations that must pass the threshold to retain the row/ feature (e.g. gene). Supplied via task.ext.args as --minimum_samples default: 1 - minimum_proportion: - type: numeric + type: float description: | A minimum proportion of observations that must pass the threshold. Supplied via task.ext.args as --minimum_proportion. Overrides minimum_samples default: 0 - grouping_variable: - type: optional string + type: string description: | Optionally supply a variable from the sample sheet that can be used to define groups and derive a minimum group size upon which to base minimum observation numbers. The rationale being to allow retention of features that might be present in only one group. Supplied via task.ext.args as --grouping_variable + - minimum_proportion_not_na: + type: float + description: | + A minimum proportion of observations that must have a numeric value (not be NA). + Supplied via task.ext.args as --minimum_proportion_not_na + default: 0.5 + - minimum_samples_not_na: + type: integer + description: | + Minimum observations that must have a numeric value (not be NA) to retain + the row/ feature (e.g. gene). Supplied via task.ext.args as + --minimum_samples_not_na. Overrides minimum_proportion_not_na output: - versions: @@ -75,6 +89,10 @@ output: type: file description: Filtered version of input matrix pattern: "*.filtered.tsv" + - tests: + type: file + description: Boolean matrix with pass/ fail status for each test on each feature + pattern: "*.tests.tsv" authors: - "@pinin4fjords" diff --git a/modules/nf-core/custom/matrixfilter/templates/matrixfilter.R b/modules/nf-core/custom/matrixfilter/templates/matrixfilter.R index 983e97cccba..dc8b508f1c2 100644 --- a/modules/nf-core/custom/matrixfilter/templates/matrixfilter.R +++ b/modules/nf-core/custom/matrixfilter/templates/matrixfilter.R @@ -78,7 +78,9 @@ opt <- list( minimum_abundance = 1, minimum_samples = 1, minimum_proportion = 0, - grouping_variable = NULL + grouping_variable = NULL, + minimum_proportion_not_na = 0.5, + minimum_samples_not_na = NULL ) opt_types <- lapply(opt, class) @@ -152,11 +154,29 @@ if ((opt\$sample_file != '') && ( ! is.null(opt\$grouping_variable))){ opt\$minimum_samples <- ncol(abundance_matrix) * opt\$minimum_proportion } -# Generate a boolean vector specifying the features to retain +# Also set up filtering for NAs; use by default minimum_proportion_not_na; only +# use minimum_samples_not_na if it is provided (default NULL) -keep <- apply(abundance_matrix, 1, function(x){ - sum(x > opt\$minimum_abundance) >= opt\$minimum_samples -}) +if (is.null(opt\$minimum_samples_not_na)) { + opt\$minimum_samples_not_na <- ncol(abundance_matrix) * opt\$minimum_proportion_not_na +} + +# Define the tests + +tests <- list( + 'abundance' = function(x) sum(x > opt\$minimum_abundance, na.rm = T) >= opt\$minimum_samples, + 'na' = function(x) !any(is.na(x)) || sum(!is.na(x))/length(x) >= opt\$minimum_samples_not_n +) + +# Apply the functions row-wise on the abundance_matrix and store the result in a boolean matrix + +boolean_matrix <- t(apply(abundance_matrix, 1, function(row) { + sapply(tests, function(f) f(row)) +})) + +# We will retain features passing all tests + +keep <- apply(boolean_matrix, 1, all) # Write out the matrix retaining the specified rows and re-prepending the # column with the feature identifiers @@ -175,6 +195,20 @@ write.table( quote = FALSE ) +# Write a boolean matrix returning specifying the status of each test + +write.table( + data.frame(rownames(abundance_matrix), boolean_matrix), + file = paste0( + prefix, + '.tests.tsv' + ), + col.names = c(feature_id_name, names(tests)), + row.names = FALSE, + sep = '\t', + quote = FALSE +) + ################################################ ################################################ ## R SESSION INFO ## diff --git a/modules/nf-core/manta/germline/main.nf b/modules/nf-core/manta/germline/main.nf index e052b7c9f0d..5232ede07af 100644 --- a/modules/nf-core/manta/germline/main.nf +++ b/modules/nf-core/manta/germline/main.nf @@ -13,6 +13,7 @@ process MANTA_GERMLINE { tuple val(meta), path(input), path(index), path(target_bed), path(target_bed_tbi) tuple val(meta2), path(fasta) tuple val(meta3), path(fai) + path(config) output: tuple val(meta), path("*candidate_small_indels.vcf.gz") , emit: candidate_small_indels_vcf @@ -31,27 +32,29 @@ process MANTA_GERMLINE { def prefix = task.ext.prefix ?: "${meta.id}" def input_files = input.collect{"--bam ${it}"}.join(' ') def options_manta = target_bed ? "--callRegions $target_bed" : "" + def config_option = config ? "--config ${config}" : "" """ - configManta.py \ - ${input_files} \ - --reference $fasta \ - --runDir manta \ - $options_manta \ + configManta.py \\ + ${input_files} \\ + ${config_option} \\ + --reference $fasta \\ + --runDir manta \\ + $options_manta \\ $args python manta/runWorkflow.py -m local -j $task.cpus - mv manta/results/variants/candidateSmallIndels.vcf.gz \ + mv manta/results/variants/candidateSmallIndels.vcf.gz \\ ${prefix}.candidate_small_indels.vcf.gz - mv manta/results/variants/candidateSmallIndels.vcf.gz.tbi \ + mv manta/results/variants/candidateSmallIndels.vcf.gz.tbi \\ ${prefix}.candidate_small_indels.vcf.gz.tbi - mv manta/results/variants/candidateSV.vcf.gz \ + mv manta/results/variants/candidateSV.vcf.gz \\ ${prefix}.candidate_sv.vcf.gz - mv manta/results/variants/candidateSV.vcf.gz.tbi \ + mv manta/results/variants/candidateSV.vcf.gz.tbi \\ ${prefix}.candidate_sv.vcf.gz.tbi - mv manta/results/variants/diploidSV.vcf.gz \ + mv manta/results/variants/diploidSV.vcf.gz \\ ${prefix}.diploid_sv.vcf.gz - mv manta/results/variants/diploidSV.vcf.gz.tbi \ + mv manta/results/variants/diploidSV.vcf.gz.tbi \\ ${prefix}.diploid_sv.vcf.gz.tbi cat <<-END_VERSIONS > versions.yml diff --git a/modules/nf-core/manta/germline/meta.yml b/modules/nf-core/manta/germline/meta.yml index 2eb16ada53a..b0cf111df65 100644 --- a/modules/nf-core/manta/germline/meta.yml +++ b/modules/nf-core/manta/germline/meta.yml @@ -57,6 +57,10 @@ input: type: file description: Genome reference FASTA index file pattern: "*.{fa.fai,fasta.fai}" + - config: + type: file + description: Manta configuration file + pattern: "*.{ini,conf,config}" output: - meta: @@ -96,3 +100,4 @@ output: authors: - "@maxulysse" - "@ramprasadn" + - "@nvnieuwk" diff --git a/modules/nf-core/manta/somatic/main.nf b/modules/nf-core/manta/somatic/main.nf index 8ff8d90a11f..5cbf7c497d1 100644 --- a/modules/nf-core/manta/somatic/main.nf +++ b/modules/nf-core/manta/somatic/main.nf @@ -10,8 +10,9 @@ process MANTA_SOMATIC { input: tuple val(meta), path(input_normal), path(input_index_normal), path(input_tumor), path(input_index_tumor), path(target_bed), path(target_bed_tbi) - path fasta - path fai + tuple val(meta2), path(fasta) + tuple val(meta3), path(fai) + path(config) output: tuple val(meta), path("*.candidate_small_indels.vcf.gz") , emit: candidate_small_indels_vcf @@ -31,26 +32,53 @@ process MANTA_SOMATIC { def args = task.ext.args ?: '' def prefix = task.ext.prefix ?: "${meta.id}" def options_manta = target_bed ? "--callRegions $target_bed" : "" - + def config_option = config ? "--config ${config}" : "" """ - configManta.py \ - --tumorBam $input_tumor \ - --normalBam $input_normal \ - --reference $fasta \ - --runDir manta \ - $options_manta \ + configManta.py \\ + --tumorBam $input_tumor \\ + --normalBam $input_normal \\ + --reference $fasta \\ + ${config_option} \\ + --runDir manta \\ + $options_manta \\ $args python manta/runWorkflow.py -m local -j $task.cpus - mv manta/results/variants/candidateSmallIndels.vcf.gz ${prefix}.candidate_small_indels.vcf.gz - mv manta/results/variants/candidateSmallIndels.vcf.gz.tbi ${prefix}.candidate_small_indels.vcf.gz.tbi - mv manta/results/variants/candidateSV.vcf.gz ${prefix}.candidate_sv.vcf.gz - mv manta/results/variants/candidateSV.vcf.gz.tbi ${prefix}.candidate_sv.vcf.gz.tbi - mv manta/results/variants/diploidSV.vcf.gz ${prefix}.diploid_sv.vcf.gz - mv manta/results/variants/diploidSV.vcf.gz.tbi ${prefix}.diploid_sv.vcf.gz.tbi - mv manta/results/variants/somaticSV.vcf.gz ${prefix}.somatic_sv.vcf.gz - mv manta/results/variants/somaticSV.vcf.gz.tbi ${prefix}.somatic_sv.vcf.gz.tbi + mv manta/results/variants/candidateSmallIndels.vcf.gz \\ + ${prefix}.candidate_small_indels.vcf.gz + mv manta/results/variants/candidateSmallIndels.vcf.gz.tbi \\ + ${prefix}.candidate_small_indels.vcf.gz.tbi + mv manta/results/variants/candidateSV.vcf.gz \\ + ${prefix}.candidate_sv.vcf.gz + mv manta/results/variants/candidateSV.vcf.gz.tbi \\ + ${prefix}.candidate_sv.vcf.gz.tbi + mv manta/results/variants/diploidSV.vcf.gz \\ + ${prefix}.diploid_sv.vcf.gz + mv manta/results/variants/diploidSV.vcf.gz.tbi \\ + ${prefix}.diploid_sv.vcf.gz.tbi + mv manta/results/variants/somaticSV.vcf.gz \\ + ${prefix}.somatic_sv.vcf.gz + mv manta/results/variants/somaticSV.vcf.gz.tbi \\ + ${prefix}.somatic_sv.vcf.gz.tbi + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + manta: \$( configManta.py --version ) + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + """ + touch ${prefix}.candidate_small_indels.vcf.gz + touch ${prefix}.candidate_small_indels.vcf.gz.tbi + touch ${prefix}.candidate_sv.vcf.gz + touch ${prefix}.candidate_sv.vcf.gz.tbi + touch ${prefix}.diploid_sv.vcf.gz + touch ${prefix}.diploid_sv.vcf.gz.tbi + touch ${prefix}.somatic_sv.vcf.gz + touch ${prefix}.somatic_sv.vcf.gz.tbi cat <<-END_VERSIONS > versions.yml "${task.process}": diff --git a/modules/nf-core/manta/somatic/meta.yml b/modules/nf-core/manta/somatic/meta.yml index 457d66a5fdd..e59e3002d07 100644 --- a/modules/nf-core/manta/somatic/meta.yml +++ b/modules/nf-core/manta/somatic/meta.yml @@ -47,14 +47,28 @@ input: type: file description: Index for BED file containing target regions for variant calling pattern: "*.{bed.tbi}" + - meta2: + type: map + description: | + Groovy Map containing reference information + e.g. [ id:'genome' ] - fasta: type: file description: Genome reference FASTA file pattern: "*.{fa,fasta}" + - meta3: + type: map + description: | + Groovy Map containing reference information + e.g. [ id:'genome' ] - fai: type: file description: Genome reference FASTA index file pattern: "*.{fa.fai,fasta.fai}" + - config: + type: file + description: Manta configuration file + pattern: "*.{ini,conf,config}" output: - meta: @@ -101,3 +115,4 @@ output: authors: - "@FriederikeHanssen" + - "@nvnieuwk" diff --git a/modules/nf-core/manta/tumoronly/main.nf b/modules/nf-core/manta/tumoronly/main.nf index e3d6ca1b142..46be430e062 100644 --- a/modules/nf-core/manta/tumoronly/main.nf +++ b/modules/nf-core/manta/tumoronly/main.nf @@ -10,8 +10,9 @@ process MANTA_TUMORONLY { input: tuple val(meta), path(input), path(input_index), path(target_bed), path(target_bed_tbi) - path fasta - path fai + tuple val(meta2), path(fasta) + tuple val(meta3), path(fai) + path(config) output: tuple val(meta), path("*candidate_small_indels.vcf.gz") , emit: candidate_small_indels_vcf @@ -29,27 +30,29 @@ process MANTA_TUMORONLY { def args = task.ext.args ?: '' def prefix = task.ext.prefix ?: "${meta.id}" def options_manta = target_bed ? "--callRegions $target_bed" : "" + def config_option = config ? "--config ${config}" : "" """ - configManta.py \ - --tumorBam $input \ - --reference $fasta \ - --runDir manta \ - $options_manta \ + configManta.py \\ + --tumorBam $input \\ + --reference $fasta \\ + ${config_option} \\ + --runDir manta \\ + $options_manta \\ $args python manta/runWorkflow.py -m local -j $task.cpus - mv manta/results/variants/candidateSmallIndels.vcf.gz \ + mv manta/results/variants/candidateSmallIndels.vcf.gz \\ ${prefix}.candidate_small_indels.vcf.gz - mv manta/results/variants/candidateSmallIndels.vcf.gz.tbi \ + mv manta/results/variants/candidateSmallIndels.vcf.gz.tbi \\ ${prefix}.candidate_small_indels.vcf.gz.tbi - mv manta/results/variants/candidateSV.vcf.gz \ + mv manta/results/variants/candidateSV.vcf.gz \\ ${prefix}.candidate_sv.vcf.gz - mv manta/results/variants/candidateSV.vcf.gz.tbi \ + mv manta/results/variants/candidateSV.vcf.gz.tbi \\ ${prefix}.candidate_sv.vcf.gz.tbi - mv manta/results/variants/tumorSV.vcf.gz \ + mv manta/results/variants/tumorSV.vcf.gz \\ ${prefix}.tumor_sv.vcf.gz - mv manta/results/variants/tumorSV.vcf.gz.tbi \ + mv manta/results/variants/tumorSV.vcf.gz.tbi \\ ${prefix}.tumor_sv.vcf.gz.tbi cat <<-END_VERSIONS > versions.yml @@ -57,4 +60,20 @@ process MANTA_TUMORONLY { manta: \$( configManta.py --version ) END_VERSIONS """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + """ + touch ${prefix}.candidate_small_indels.vcf.gz + touch ${prefix}.candidate_small_indels.vcf.gz.tbi + touch ${prefix}.candidate_sv.vcf.gz + touch ${prefix}.candidate_sv.vcf.gz.tbi + touch ${prefix}.tumor_sv.vcf.gz + touch ${prefix}.tumor_sv.vcf.gz.tbi + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + manta: \$( configManta.py --version ) + END_VERSIONS + """ } diff --git a/modules/nf-core/manta/tumoronly/meta.yml b/modules/nf-core/manta/tumoronly/meta.yml index 398d684365b..bf6f554d859 100644 --- a/modules/nf-core/manta/tumoronly/meta.yml +++ b/modules/nf-core/manta/tumoronly/meta.yml @@ -39,14 +39,28 @@ input: type: file description: Index for BED file containing target regions for variant calling pattern: "*.{bed.tbi}" + - meta2: + type: map + description: | + Groovy Map containing reference information + e.g. [ id:'genome' ] - fasta: type: file description: Genome reference FASTA file pattern: "*.{fa,fasta}" + - meta3: + type: map + description: | + Groovy Map containing reference information + e.g. [ id:'genome' ] - fai: type: file description: Genome reference FASTA index file pattern: "*.{fa.fai,fasta.fai}" + - config: + type: file + description: Manta configuration file + pattern: "*.{ini,conf,config}" output: - meta: @@ -85,3 +99,4 @@ output: authors: - "@maxulysse" + - "@nvnieuwk" diff --git a/modules/nf-core/seqkit/sliding/main.nf b/modules/nf-core/seqkit/sliding/main.nf index ffa570eb58f..0f385c68cef 100644 --- a/modules/nf-core/seqkit/sliding/main.nf +++ b/modules/nf-core/seqkit/sliding/main.nf @@ -37,4 +37,18 @@ process SEQKIT_SLIDING { seqkit: \$( seqkit | sed '3!d; s/Version: //' ) END_VERSIONS """ + + stub: + prefix = task.ext.prefix ?: "${meta.id}" + if ("$fastx" ==~ /.+\.fasta$|.+\.fa$|.+\.fas$|.+\.fna$/) { + extension = "fasta" + } + """ + touch ${prefix}.${extension} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + seqkit: \$( seqkit | sed '3!d; s/Version: //' ) + END_VERSIONS + """ } diff --git a/tests/config/test_data.config b/tests/config/test_data.config index b2191d73ae6..1c9ed34047d 100644 --- a/tests/config/test_data.config +++ b/tests/config/test_data.config @@ -641,7 +641,7 @@ params { mq_contrasts = "${params.test_data_base}/data/proteomics/maxquant/MaxQuant_contrasts.csv" mq_proteingroups = "${params.test_data_base}/data/proteomics/maxquant/MaxQuant_proteinGroups.txt" mq_samplesheet = "${params.test_data_base}/data/proteomics/maxquant/MaxQuant_samplesheet.tsv" - + mq_proteus_mat = "${params.test_data_base}/data/proteomics/maxquant/proteus.raw_MaxQuant_proteingroups_tab.tsv" } 'parameter' { maxquant = "${params.test_data_base}/data/proteomics/parameter/mqpar.xml" diff --git a/tests/modules/nf-core/custom/matrixfilter/main.nf b/tests/modules/nf-core/custom/matrixfilter/main.nf index 235b3535eb4..1484ef7c66b 100644 --- a/tests/modules/nf-core/custom/matrixfilter/main.nf +++ b/tests/modules/nf-core/custom/matrixfilter/main.nf @@ -43,3 +43,31 @@ workflow test_custom_matrixfilter_group { ch_samplesheet ) } + +workflow test_custom_matrixfilter_na_prop { + + expression_sample_sheet = file(params.test_data['proteomics']['maxquant']['mq_samplesheet'], checkIfExists: true) + expression_matrix_file = file(params.test_data['proteomics']['maxquant']['mq_proteus_mat'], checkIfExists: true) + + ch_samples_matrix = [ [ "id":"mq_prop" ], expression_matrix_file ] + ch_samplesheet = [ [ "id":"mq_prop" ], expression_sample_sheet ] + + CUSTOM_MATRIXFILTER( + ch_samples_matrix, + ch_samplesheet + ) +} + +workflow test_custom_matrixfilter_na_samples { + + expression_sample_sheet = file(params.test_data['proteomics']['maxquant']['mq_samplesheet'], checkIfExists: true) + expression_matrix_file = file(params.test_data['proteomics']['maxquant']['mq_proteus_mat'], checkIfExists: true) + + ch_samples_matrix = [ [ "id":"mq_samples" ], expression_matrix_file ] + ch_samplesheet = [ [ "id":"mq_samples" ], expression_sample_sheet ] + + CUSTOM_MATRIXFILTER( + ch_samples_matrix, + ch_samplesheet + ) +} diff --git a/tests/modules/nf-core/custom/matrixfilter/nextflow.config b/tests/modules/nf-core/custom/matrixfilter/nextflow.config index 87717ff8c09..25260f207a0 100644 --- a/tests/modules/nf-core/custom/matrixfilter/nextflow.config +++ b/tests/modules/nf-core/custom/matrixfilter/nextflow.config @@ -16,4 +16,14 @@ process { ext.args = { "--minimum_proportion 1 --grouping_variable treatment" } ext.prefix = { "${meta.id}_test" } } + + withName: 'test_custom_matrixfilter_na_prop:CUSTOM_MATRIXFILTER' { + ext.args = { "--sample_id_col Experiment --minimum_abundance 20" } + ext.prefix = { "${meta.id}_test" } + } + + withName: 'test_custom_matrixfilter_na_samples:CUSTOM_MATRIXFILTER' { + ext.args = { "--sample_id_col Experiment --minimum_abundance 28 --minimum_samples_not_na 1" } + ext.prefix = { "${meta.id}_test" } + } } diff --git a/tests/modules/nf-core/custom/matrixfilter/test.yml b/tests/modules/nf-core/custom/matrixfilter/test.yml index 46d6e2789a1..cf86a8bacf2 100644 --- a/tests/modules/nf-core/custom/matrixfilter/test.yml +++ b/tests/modules/nf-core/custom/matrixfilter/test.yml @@ -4,8 +4,12 @@ - custom - custom/matrixfilter files: + - path: output/custom/R_sessionInfo.log - path: output/custom/SRP254919_test.filtered.tsv md5sum: 84f2a16e50f5ce9d38e8176fb324ebe0 + - path: output/custom/SRP254919_test.tests.tsv + md5sum: 25657e1730d849b529ab34bfa52f0e1f + - path: output/custom/versions.yml - name: custom matrixfilter test_custom_matrixfilter_prop command: nextflow run ./tests/modules/nf-core/custom/matrixfilter -entry test_custom_matrixfilter_prop -c ./tests/config/nextflow.config -c ./tests/modules/nf-core/custom/matrixfilter/nextflow.config @@ -13,8 +17,12 @@ - custom - custom/matrixfilter files: + - path: output/custom/R_sessionInfo.log - path: output/custom/SRP254919_test.filtered.tsv md5sum: 8cf3de07e8a37ce6a8dea40c7a696a79 + - path: output/custom/SRP254919_test.tests.tsv + md5sum: ebd549b0e395f705e92854f4f8943290 + - path: output/custom/versions.yml - name: custom matrixfilter test_custom_matrixfilter_group command: nextflow run ./tests/modules/nf-core/custom/matrixfilter -entry test_custom_matrixfilter_group -c ./tests/config/nextflow.config -c ./tests/modules/nf-core/custom/matrixfilter/nextflow.config @@ -22,5 +30,35 @@ - custom - custom/matrixfilter files: + - path: output/custom/R_sessionInfo.log - path: output/custom/SRP254919_test.filtered.tsv md5sum: 6b25196c3bc03167dbdddc03cfa90a29 + - path: output/custom/SRP254919_test.tests.tsv + md5sum: 00e8c7a0ef2556dec525c43fbae50493 + - path: output/custom/versions.yml + +- name: custom matrixfilter test_custom_matrixfilter_na_prop + command: nextflow run ./tests/modules/nf-core/custom/matrixfilter -entry test_custom_matrixfilter_na_prop -c ./tests/config/nextflow.config -c ./tests/modules/nf-core/custom/matrixfilter/nextflow.config + tags: + - custom + - custom/matrixfilter + files: + - path: output/custom/R_sessionInfo.log + - path: output/custom/mq_prop_test.filtered.tsv + md5sum: a0943baaa48ea76bdb8c80a580dc9953 + - path: output/custom/mq_prop_test.tests.tsv + md5sum: 65f7c7ad7e475d82985bd3fc4fec0451 + - path: output/custom/versions.yml + +- name: custom matrixfilter test_custom_matrixfilter_na_samples + command: nextflow run ./tests/modules/nf-core/custom/matrixfilter -entry test_custom_matrixfilter_na_samples -c ./tests/config/nextflow.config -c ./tests/modules/nf-core/custom/matrixfilter/nextflow.config + tags: + - custom + - custom/matrixfilter + files: + - path: output/custom/R_sessionInfo.log + - path: output/custom/mq_samples_test.filtered.tsv + md5sum: f0d81baf35d7eb324365ad5e1c6eb2ae + - path: output/custom/mq_samples_test.tests.tsv + md5sum: c9e91fb2e26ba8f5d3c73f0d2252fb56 + - path: output/custom/versions.yml diff --git a/tests/modules/nf-core/manta/germline/main.nf b/tests/modules/nf-core/manta/germline/main.nf index 1e0ac26c5a0..b6be6c2d741 100644 --- a/tests/modules/nf-core/manta/germline/main.nf +++ b/tests/modules/nf-core/manta/germline/main.nf @@ -18,7 +18,10 @@ workflow test_manta_germline { file(params.test_data['homo_sapiens']['genome']['genome_fasta_fai'], checkIfExists: true) ] - MANTA_GERMLINE ( input, fasta, fai ) + config = Channel.of("[manta]", "enableRemoteReadRetrievalForInsertionsInGermlineCallingModes = 0") + .collectFile(name:"manta_options.ini", newLine:true) + + MANTA_GERMLINE ( input, fasta, fai, config ) } workflow test_manta_germline_target_bed { @@ -36,7 +39,7 @@ workflow test_manta_germline_target_bed { file(params.test_data['homo_sapiens']['genome']['genome_fasta_fai'], checkIfExists: true) ] - MANTA_GERMLINE ( input, fasta, fai ) + MANTA_GERMLINE ( input, fasta, fai, [] ) } workflow test_manta_germline_target_bed_jointcalling { @@ -56,5 +59,5 @@ workflow test_manta_germline_target_bed_jointcalling { file(params.test_data['homo_sapiens']['genome']['genome_fasta_fai'], checkIfExists: true) ] - MANTA_GERMLINE ( input, fasta, fai ) + MANTA_GERMLINE ( input, fasta, fai, [] ) } diff --git a/tests/modules/nf-core/manta/somatic/main.nf b/tests/modules/nf-core/manta/somatic/main.nf index 2fdceb00011..89296959f24 100644 --- a/tests/modules/nf-core/manta/somatic/main.nf +++ b/tests/modules/nf-core/manta/somatic/main.nf @@ -15,10 +15,18 @@ workflow test_manta_somatic { [], [] ] - 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) + fasta = [ [id:'genome'], + file(params.test_data['homo_sapiens']['genome']['genome_21_fasta'], checkIfExists: true) + ] - MANTA_SOMATIC ( input, fasta, fai ) + fai = [ [id:'genome'], + file(params.test_data['homo_sapiens']['genome']['genome_21_fasta_fai'], checkIfExists: true) + ] + + config = Channel.of("[manta]", "enableRemoteReadRetrievalForInsertionsInGermlineCallingModes = 0") + .collectFile(name:"manta_options.ini", newLine:true) + + MANTA_SOMATIC ( input, fasta, fai, config ) } workflow test_manta_somatic_target_bed { @@ -33,8 +41,13 @@ workflow test_manta_somatic_target_bed { file(params.test_data['homo_sapiens']['genome']['genome_21_multi_interval_bed_gz_tbi'], checkIfExists: true), ] - 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) + fasta = [ [id:'genome'], + file(params.test_data['homo_sapiens']['genome']['genome_21_fasta'], checkIfExists: true) + ] + + fai = [ [id:'genome'], + file(params.test_data['homo_sapiens']['genome']['genome_21_fasta_fai'], checkIfExists: true) + ] - MANTA_SOMATIC ( input, fasta, fai ) + MANTA_SOMATIC ( input, fasta, fai, [] ) } diff --git a/tests/modules/nf-core/manta/tumoronly/main.nf b/tests/modules/nf-core/manta/tumoronly/main.nf index dccf5591ba2..11f52f2786b 100644 --- a/tests/modules/nf-core/manta/tumoronly/main.nf +++ b/tests/modules/nf-core/manta/tumoronly/main.nf @@ -12,10 +12,18 @@ workflow test_manta_tumoronly { [], [] ] - 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) + fasta = [ [id:'genome'], + file(params.test_data['homo_sapiens']['genome']['genome_21_fasta'], checkIfExists: true) + ] - MANTA_TUMORONLY ( input, fasta, fai ) + fai = [ [id:'genome'], + file(params.test_data['homo_sapiens']['genome']['genome_21_fasta_fai'], checkIfExists: true) + ] + + config = Channel.of("[manta]", "enableRemoteReadRetrievalForInsertionsInGermlineCallingModes = 0") + .collectFile(name:"manta_options.ini", newLine:true) + + MANTA_TUMORONLY ( input, fasta, fai, config ) } workflow test_manta_tumoronly_target_bed { @@ -27,8 +35,13 @@ workflow test_manta_tumoronly_target_bed { file(params.test_data['homo_sapiens']['genome']['genome_21_multi_interval_bed_gz_tbi'], checkIfExists: true) ] - 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) + fasta = [ [id:'genome'], + file(params.test_data['homo_sapiens']['genome']['genome_21_fasta'], checkIfExists: true) + ] + + fai = [ [id:'genome'], + file(params.test_data['homo_sapiens']['genome']['genome_21_fasta_fai'], checkIfExists: true) + ] - MANTA_TUMORONLY ( input, fasta, fai ) + MANTA_TUMORONLY ( input, fasta, fai, [] ) }