-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathextract_ancestral.nf
executable file
·50 lines (41 loc) · 1.6 KB
/
extract_ancestral.nf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
process EXTRACT_ANCESTRAL {
tag "$meta.id"
label 'process_low'
conda "conda-forge::python=3.9"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/python:3.9' :
'biocontainers/python:3.9' }"
input:
tuple val(meta), path(fulltable)
path(ancestraltable)
output:
tuple val(meta), path("*buscopainter_complete_location.tsv") , emit: comp_location
path("*buscopainter_duplicated_location.tsv") , emit: dup_location
path("*summary.tsv") , emit: summary
path "versions.yml" , emit: versions
when:
task.ext.when == null || task.ext.when
script:
def args = task.ext.args ?: ''
def prefix = task.ext.prefix ?: "${meta.id}"
"""
buscopainter.py -r $ancestraltable -q $fulltable
cat <<-END_VERSIONS > versions.yml
"${task.process}":
python: \$(echo \$(python --version 2>&1) | sed 's/^.*python //; s/Using.*\$//')
buscopainter.py: \$(buscopainter.py -v)
END_VERSIONS
"""
stub:
def prefix = task.ext.prefix ?: "${meta.id}"
"""
touch ${prefix}_buscopainter_complete_location.tsv
touch ${prefox}_buscopainter_duplicated_location.tsv
touch ${prefix}_summary.tsv
cat <<-END_VERSIONS > versions.yml
"${task.process}":
python: \$(echo \$(python --version 2>&1) | sed 's/^.*python //; s/Using.*\$//')
buscopainter.py: \$(buscopainter.py -v)
END_VERSIONS
"""
}