4

Nextflow allows to efficiently make complex pipelines. Some people understand things only visually, so it's important to make a good graphical representation. Way to do so in nextflow is by -with-dag command:

nextflow run <script-name> -with-dag flowchart.png

However, output looks bad and doesn't have any professional vibe to it:

enter image description here

I wonder if there are any ways to improve it, like getting source code and uploading on some different visualisation programms. Anything.

juststuck
  • 616
  • 5
  • 17

2 Answers2

2

Use DOT format output and Graphviz

tl;dr: Use the -with-dag flag without a filename and use Graphviz to render the resulting dag.dot file.

Graphvis is a software package built specifically for visualizing these sorts of graphs. Nextflow's DAG visualization option will output a DOT format representation by default. Instead of specifying -with-dag flowchart.png use the naked flag -with-dag to emit dag.dot or specify the filename of your choice with the .dot extension. Rendering a dot file to a visualization is the subject of other questions and documentation.

GcL
  • 501
  • 6
  • 16
0

Apart from GcL's solution that allows you to use whatever solution you want based on the dot file, Nextflow currently supports an interactive HTML/JS DAG. You can quickly view an example of how it looks like with the command below:

nextflow run -resume nextflow-io/rnaseq-nf -r dev -with-dag dag.html

PS: If you don't have Docker running in your machine, set -without-docker, but this will require you to have some dependencies installed such as fastqc. Having the information within the dot file allows you to use things like dagviz which, in my opinion, is pretty neat.

mribeirodantas
  • 339
  • 1
  • 6