mirror of
https://github.com/MillironX/nf-core_modules.git
synced 2024-12-22 02:58:17 +00:00
add intervals possibilities to splitncigarreads (#1571)
This commit is contained in:
parent
61e740f79c
commit
10ca39a86f
4 changed files with 37 additions and 3 deletions
|
@ -8,7 +8,7 @@ process GATK4_SPLITNCIGARREADS {
|
|||
'quay.io/biocontainers/gatk4:4.2.5.0--hdfd78af_0' }"
|
||||
|
||||
input:
|
||||
tuple val(meta), path(bam)
|
||||
tuple val(meta), path(bam), path(bai), path(intervals)
|
||||
path fasta
|
||||
path fai
|
||||
path dict
|
||||
|
@ -23,6 +23,7 @@ process GATK4_SPLITNCIGARREADS {
|
|||
script:
|
||||
def args = task.ext.args ?: ''
|
||||
def prefix = task.ext.prefix ?: "${meta.id}"
|
||||
def interval_command = intervals ? "--intervals $intervals" : ""
|
||||
|
||||
def avail_mem = 3
|
||||
if (!task.memory) {
|
||||
|
@ -35,6 +36,7 @@ process GATK4_SPLITNCIGARREADS {
|
|||
--input $bam \\
|
||||
--output ${prefix}.bam \\
|
||||
--reference $fasta \\
|
||||
$interval_command \\
|
||||
--tmp-dir . \\
|
||||
$args
|
||||
|
||||
|
|
|
@ -23,6 +23,13 @@ input:
|
|||
type: list
|
||||
description: BAM/SAM/CRAM file containing reads
|
||||
pattern: "*.{bam,sam,cram}"
|
||||
- bai:
|
||||
type: list
|
||||
description: BAI/SAI/CRAI index file (optional)
|
||||
pattern: "*.{bai,sai,crai}"
|
||||
- intervals:
|
||||
type: file
|
||||
description: Bed file with the genomic regions included in the library (optional)
|
||||
- fasta:
|
||||
type: file
|
||||
description: The reference fasta file
|
||||
|
|
|
@ -6,7 +6,23 @@ include { GATK4_SPLITNCIGARREADS } from '../../../../modules/gatk4/splitncigarre
|
|||
|
||||
workflow test_gatk4_splitncigarreads {
|
||||
input = [ [ id:'test' ], // meta map
|
||||
[ file(params.test_data['sarscov2']['illumina']['test_paired_end_bam'], checkIfExists: true) ]
|
||||
file(params.test_data['sarscov2']['illumina']['test_paired_end_bam'], checkIfExists: true),
|
||||
[],
|
||||
[]
|
||||
]
|
||||
|
||||
fasta = file(params.test_data['sarscov2']['genome']['genome_fasta'], checkIfExists: true)
|
||||
fai = file(params.test_data['sarscov2']['genome']['genome_fasta_fai'], checkIfExists: true)
|
||||
dict = file(params.test_data['sarscov2']['genome']['genome_dict'], checkIfExists: true)
|
||||
|
||||
GATK4_SPLITNCIGARREADS ( input, fasta, fai, dict )
|
||||
}
|
||||
|
||||
workflow test_gatk4_splitncigarreads_intervals {
|
||||
input = [ [ id:'test' ], // meta map
|
||||
file(params.test_data['sarscov2']['illumina']['test_paired_end_sorted_bam'], checkIfExists: true),
|
||||
file(params.test_data['sarscov2']['illumina']['test_paired_end_sorted_bam_bai'], checkIfExists: true),
|
||||
file(params.test_data['sarscov2']['genome']['test_bed'], checkIfExists: true)
|
||||
]
|
||||
fasta = file(params.test_data['sarscov2']['genome']['genome_fasta'], checkIfExists: true)
|
||||
fai = file(params.test_data['sarscov2']['genome']['genome_fasta_fai'], checkIfExists: true)
|
||||
|
|
|
@ -5,5 +5,14 @@
|
|||
- gatk4/splitncigarreads
|
||||
files:
|
||||
- path: output/gatk4/test.bam
|
||||
md5sum: ceed15c0bd64ff5c38d3816905933b0b
|
||||
md5sum: 436d8e31285c6b588bdd1c7f1d07f6f2
|
||||
- path: output/gatk4/versions.yml
|
||||
- name: gatk4 splitncigarreads test_gatk4_splitncigarreads_intervals
|
||||
command: nextflow run tests/modules/gatk4/splitncigarreads -entry test_gatk4_splitncigarreads_intervals -c tests/config/nextflow.config
|
||||
tags:
|
||||
- gatk4
|
||||
- gatk4/splitncigarreads
|
||||
files:
|
||||
- path: output/gatk4/test.bam
|
||||
md5sum: cd56e3225950f519fd47164cca60a0bb
|
||||
- path: output/gatk4/versions.yml
|
||||
|
|
Loading…
Reference in a new issue