cluster location in graphviz python

2019-09-17 20:08发布

问题:

Is there a way to make this graphviz output

looks like

I am using subgraphs, to merge the 4 clusters with the tree graph

回答1:

Googling found an answer: http://www.graphviz.org/content/subgraph-different-rankdir
Essentially, subgraphs can't have their own rankdir, but you can get the effect you want by placing invisible links between the top-level objects, causing them to be laid out top-to-bottom.