comparison nf/subworkflows/ncbi/target_proteins/main.nf @ 0:d9c5c5b87fec draft

planemo upload for repository https://github.com/ncbi/egapx commit 8173d01b08d9a91c9ec5f6cb50af346edc8020c4
author fubar
date Sat, 03 Aug 2024 11:16:53 +0000
parents
children
comparison
equal deleted inserted replaced
-1:000000000000 0:d9c5c5b87fec
1 #!/usr/bin/env nextflow
2 // main nextflow script for EGAPx execution
3 // route data to subworkflows
4
5 nextflow.enable.dsl=2
6
7 include { miniprot } from './miniprot/main'
8 include { align_filter_sa } from './align_filter_sa/main'
9 include { best_aligned_prot } from './best_aligned_prot/main'
10 include { paf2asn } from './paf2asn/main'
11 include { run_align_sort} from '../default/align_sort_sa/main'
12
13 params.intermediate = false
14
15
16 workflow target_proteins_plane {
17 take:
18 unpacked_genome_fasta
19 genome_asn
20 gencoll_asn
21 unpacked_proteins_fasta
22 proteins_asn
23 max_intron
24 task_params // task parameters for every task
25 main:
26 // Protein alignments
27 miniprot(unpacked_genome_fasta, unpacked_proteins_fasta, max_intron, task_params.get('miniprot', [:]))
28 def miniprot_file = miniprot.out.miniprot_file
29 paf2asn(genome_asn, proteins_asn, miniprot_file, task_params.get('paf2asn', [:]))
30 def converted_asn = paf2asn.out.asn_file
31 best_aligned_prot(genome_asn, proteins_asn, converted_asn.collect(), gencoll_asn, task_params.get('best_aligned_prot', [:]))
32 align_filter_sa(genome_asn, proteins_asn, best_aligned_prot.out.asn_file, task_params.get('align_filter_sa', [:]))
33 run_align_sort(genome_asn, proteins_asn,align_filter_sa.out.filtered_file,
34 "-k subject,subject_start,-subject_end,subject_strand,query,query_start,-query_end,query_strand,-num_ident,gap_count" )
35 emit:
36 protein_alignments = run_align_sort.out
37 }