luslab-umitools | Added index output from module

This commit is contained in:
Chris Cheshire 2020-06-26 09:04:15 +01:00
parent 3e26c218c2
commit afb1adebb6
3 changed files with 9 additions and 9 deletions

View file

@ -7,3 +7,4 @@ channels:
- defaults - defaults
dependencies: dependencies:
- umi_tools=1.0.1 - umi_tools=1.0.1
- samtools=1.1.0

View file

@ -17,7 +17,8 @@ process umitools_dedup {
tuple val(sample_id), path(bam) tuple val(sample_id), path(bam)
output: output:
tuple val(sample_id), path("*.dedup.bam"), emit: dedupBam tuple val(sample_id), path("${sample_id}.dedup.bam"), emit: dedupBam
tuple val(sample_id), path("${sample_id}.dedup.bam.bai"), emit: dedupBai
path "*.dedup.log", emit: report path "*.dedup.log", emit: report
script: script:
@ -32,15 +33,16 @@ process umitools_dedup {
} }
// Contruct CL line // Contruct CL line
command = "umi_tools dedup ${args} -I ${bam[0]} -S ${sample_id}.dedup.bam --output-stats=${sample_id}" dedup_command = "umi_tools dedup ${args} -I ${bam[0]} -S ${sample_id}.dedup.bam --output-stats=${sample_id}"
// Log // Log
if (params.verbose){ if (params.verbose){
println ("[MODULE] umi_tools/dedup exec: " + command) println ("[MODULE] umi_tools/dedup command: " + dedup_command)
} }
//SHELL //SHELL
""" """
${command} ${dedup_command}
samtools index ${sample_id}.dedup.bam
""" """
} }

View file

@ -24,12 +24,9 @@ processes:
- sample_id: - sample_id:
type: string type: string
description: Sample identifier description: Sample identifier
- bai:
type: file
description: BAM file index
- bam: - bam:
type: file type: file array
description: BAM sequence file description: BAM sequence file and associated BAI index file
output: output:
- dedupBam: - dedupBam:
type: tuple type: tuple