Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Best way to combine Nextflow pipelines within Nextflow

Tags:

nextflow

I'm new to NextFlow and I wonder which is the best way to call NextFlow pipelines within my new pipeline? I know I can call processes individually, but I'm interested in calling the overall pipeline so I can combine multiple nf scripts.

like image 280
aLbAc Avatar asked Oct 19 '25 13:10

aLbAc


1 Answers

That's what we call subworkflows. In DSL2, the default DSL for Nextflow currently, you can have numerous workflow entries in your .nf workflow file. With that, you can not only call these subworkflows (named workflow entries) from the main workflow (unnamed), but also from the CLI with -entry workflow-name.

You can also import workflows from other .nf files to your current one, the same way you do with modules. This way, your default unnamed workflow can also run the workflow block of other .nf files.

Let's say you have a pipeline that does A (with many processes within it), another pipeline B (with many processes within it) and you have a pipeline C in which you'd like to call these two from within it. Import the processes/workflows from A and B and call them from your unnamed workflow block in C.

like image 77
mribeirodantas Avatar answered Oct 21 '25 11:10

mribeirodantas



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!