mirror of
https://github.com/MillironX/nf-core_modules.git
synced 2024-12-22 11:08:17 +00:00
Fix bedtools intersect module
This commit is contained in:
parent
a37b116186
commit
38964ecfc0
4 changed files with 20 additions and 16 deletions
|
@ -11,7 +11,7 @@ process BEDTOOLS_INTERSECT {
|
|||
mode: params.publish_dir_mode,
|
||||
saveAs: { filename -> saveFiles(filename:filename, options:params.options, publish_dir:getSoftwareName(task.process), publish_id:meta.id) }
|
||||
|
||||
conda (params.enable_conda ? "bioconda::bedtools=2.30.0" : null)
|
||||
conda (params.enable_conda ? "bioconda::bedtools=2.30.0=hc088bd4_0" : null)
|
||||
if (workflow.containerEngine == 'singularity' && !params.singularity_pull_docker_container) {
|
||||
container "https://depot.galaxyproject.org/singularity/bedtools:2.30.0--hc088bd4_0"
|
||||
} else {
|
||||
|
@ -22,8 +22,8 @@ process BEDTOOLS_INTERSECT {
|
|||
tuple val(meta), path(bed1), path(bed2)
|
||||
|
||||
output:
|
||||
tuple val(meta), path('*.intersect.bed'), emit: bed
|
||||
path '*.version.txt' , emit: version
|
||||
tuple val(meta), path('*.bed'), emit: bed
|
||||
path '*.version.txt' , emit: version
|
||||
|
||||
script:
|
||||
def software = getSoftwareName(task.process)
|
||||
|
@ -31,10 +31,10 @@ process BEDTOOLS_INTERSECT {
|
|||
"""
|
||||
bedtools \\
|
||||
intersect \\
|
||||
-a ${bed1} \\
|
||||
-b ${bed2} \\
|
||||
-a $bed1 \\
|
||||
-b $bed2 \\
|
||||
$options.args \\
|
||||
> ${prefix}.intersect.bed
|
||||
> ${prefix}.bed
|
||||
|
||||
bedtools --version | sed -e "s/bedtools v//g" > ${software}.version.txt
|
||||
"""
|
||||
|
|
|
@ -24,7 +24,11 @@ params:
|
|||
description: |
|
||||
Run the module with Conda using the software specified
|
||||
via the `conda` directive
|
||||
|
||||
- singularity_pull_docker_container:
|
||||
type: boolean
|
||||
description: |
|
||||
Instead of directly downloading Singularity images for use with Singularity,
|
||||
force the workflow to pull and convert Docker containers instead.
|
||||
input:
|
||||
- meta:
|
||||
type: map
|
||||
|
@ -33,13 +37,12 @@ input:
|
|||
e.g. [ id:'test', single_end:false ]
|
||||
- bed1:
|
||||
type: file
|
||||
description: Bed file, each feature in 1 is compared to 2 in search of overlaps
|
||||
description: BED file, each feature in 1 is compared to 2 in search of overlaps
|
||||
pattern: "*.{bed}"
|
||||
- bed2:
|
||||
type: file
|
||||
description: Second bed file, used to compare to 1.
|
||||
description: Second bed file, used to compare to first BED file
|
||||
pattern: "*.{bed}"
|
||||
|
||||
output:
|
||||
- meta:
|
||||
type: map
|
||||
|
@ -48,12 +51,13 @@ output:
|
|||
e.g. [ id:'test', single_end:false ]
|
||||
- bed:
|
||||
type: file
|
||||
description: Overlapped bed file
|
||||
pattern: "*.{intersect.bed}"
|
||||
description: BED file with intersected intervals
|
||||
pattern: "*.{bed}"
|
||||
- version:
|
||||
type: file
|
||||
description: File containing software version
|
||||
pattern: "*.{version.txt}"
|
||||
authors:
|
||||
-"@Emiller88"
|
||||
-"@sruthipsuresh"
|
||||
- "@Emiller88"
|
||||
- "@sruthipsuresh"
|
||||
- "@drpatelh"
|
||||
|
|
|
@ -10,5 +10,5 @@ workflow test_bedtools_intersect {
|
|||
file("${launchDir}/tests/data/bed/A.bed", checkIfExists: true),
|
||||
file("${launchDir}/tests/data/bed/B.bed", checkIfExists: true) ]
|
||||
|
||||
BEDTOOLS_INTERSECT( input )
|
||||
BEDTOOLS_INTERSECT ( input )
|
||||
}
|
||||
|
|
|
@ -4,5 +4,5 @@
|
|||
- bedtools
|
||||
- bedtools_intersect
|
||||
files:
|
||||
- path: output/bedtools/test.intersect.bed
|
||||
- path: output/bedtools/test.bed
|
||||
md5sum: cc1bb317886e7df0a942b56f8a320d9c
|
||||
|
|
Loading…
Reference in a new issue