annotate 0.6.1/modules/bcs_results/main.nf @ 13:74baf1a6c3bd

"planemo upload"
author kkonganti
date Tue, 05 Sep 2023 13:04:15 -0400
parents 749faef1caa9
children
rev   line source
kkonganti@11 1 process BCS_RESULTS {
kkonganti@11 2 tag "bettercallsal aggregate"
kkonganti@11 3 label "process_pico"
kkonganti@11 4
kkonganti@11 5 module (params.enable_module ? "${params.swmodulepath}${params.fs}python${params.fs}3.8.1" : null)
kkonganti@11 6 conda (params.enable_conda ? "conda-forge::python=3.10 conda-forge::pyyaml" : null)
kkonganti@11 7 container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
kkonganti@11 8 'https://depot.galaxyproject.org/singularity/multiqc:1.14--pyhdfd78af_0' :
kkonganti@11 9 'quay.io/biocontainers/multiqc:1.14--pyhdfd78af_0' }"
kkonganti@11 10
kkonganti@11 11 input:
kkonganti@11 12 path salmon_res_dirs
kkonganti@11 13
kkonganti@11 14 output:
kkonganti@11 15 path 'bettercallsal*.tblsum.txt', emit: mqc_txt, optional: true
kkonganti@11 16 path 'bettercallsal*_mqc.json' , emit: mqc_json, optional: true
kkonganti@11 17 path 'bettercallsal*_mqc.yml' , emit: mqc_yml, optional: true
kkonganti@11 18 path 'versions.yml' , emit: versions
kkonganti@11 19
kkonganti@11 20 when:
kkonganti@11 21 task.ext.when == null || task.ext.when
kkonganti@11 22
kkonganti@11 23 script:
kkonganti@11 24 def args = task.ext.args ?: ''
kkonganti@11 25 args += (params.tuspy_ps ? " -pickle ${params.tuspy_ps}" : '')
kkonganti@11 26 args += (params.gsrpy_snp_clus_metadata ? " -snp ${params.gsrpy_snp_clus_metadata}" : '')
kkonganti@11 27 """
kkonganti@11 28 gen_salmon_res_table.py \\
kkonganti@11 29 $args \\
kkonganti@11 30 -sal "."
kkonganti@11 31
kkonganti@11 32 create_mqc_data_table.py \\
kkonganti@11 33 "bettercallsal" "The following table is an aggregation of serotype calls from all samples which also includes read counts from <code>salmon quant</code> results."
kkonganti@11 34
kkonganti@11 35 create_mqc_data_table.py \\
kkonganti@11 36 "bettercallsal_salyn" "The following table summarizes serotype presence or absence for all samples."
kkonganti@11 37
kkonganti@11 38 cat <<-END_VERSIONS > versions.yml
kkonganti@11 39 "${task.process}":
kkonganti@11 40 python: \$( python --version | sed 's/Python //g' )
kkonganti@11 41 END_VERSIONS
kkonganti@11 42 """
kkonganti@11 43 }