view nf/subworkflows/ncbi/gnomon/diamond/main.nf @ 8:1680e72e27be draft default tip

planemo upload for repository https://github.com/ncbi/egapx commit bdbe05027c2c40e217a2ff0c9e0556450c443e54
author fubar
date Mon, 05 Aug 2024 03:56:41 +0000
parents d9c5c5b87fec
children
line wrap: on
line source

#!/usr/bin/env nextflow
nextflow.enable.dsl=2

include { merge_params; to_map; shellSplit } from '../../utilities'
include { run_diamond_egap;} from '../../shared/diamond/main'


workflow diamond_worker {
    take:
        gnomon_prot_ids
        swiss_prot_ids
        gnomon_prot_asn
        swiss_prot_asn
        parameters  // Map : extra parameter and parameter update
    main:
        String diamond_blastp_params = merge_params('--sam-query-len --very-sensitive --unal 0 --comp-based-stats 0 --masking 0', parameters, 'diamond_blastp')
        String diamond_regular_params = merge_params('-ofmt seq-align-set -query-fmt seq-ids -subject-fmt seq-ids -output-prefix hits', parameters, 'diamond')
        String diamond_egap_params = '-blastp-args \''  + diamond_blastp_params + '\' '  + diamond_regular_params
        
        run_diamond_egap(gnomon_prot_ids, swiss_prot_ids, gnomon_prot_asn, swiss_prot_asn, diamond_egap_params)

    emit:
        alignments = run_diamond_egap.out
}