gvpack aspect ratio

Dear Wizards,

I use graphviz for automated vizualization of jobs, where the jobs often depend on each other (directed graphs).

Initially, I just used dot - and got very wide figures. I have now added unflatten steps - both to put single nodes (no edges) in "columns" (unflatten -c) and using the fan-out part. But the plots are still rather wide.

I have read up on the questions and comments on the forum and I am now moving towards the use of gvpack piped to neato to get a better aspect ratio. Presently, my command looks something along the lines of:

cat my.dot | ccomps -x | unflatten -l 3 -f | dot | gvpack -n | neato -n2 -Tpng -o my.png

In the above I have omitted stuff like -Glabel content, size and position, which I presently add in the neato step for the first parts to give "nice" results.
The resulting figure is much "less wide" (aspect ratio close to 1:1) than the previous tries, so things are working...

However, I do have a little way to go yet.

Ideally, I would like an aspect ratio on the final plot close to a standard HD monitor, i.e. about 1:2. As far as I can see, it is not possible to tell gvpack a "target" aspect ratio - it will work towards 1:1, unless the array-mode is used. Unfortunately, my disjoint sub-graphs vary a lot in size (#nodes) from one node to, say, tens of nodes. As a result, "gvpack -array" leaves me with a *lot* of whitespace.

In principle, it might be possible(?) to divide the disjoint graphs in two sets with roughly the same number of nodes (although it is difficult to do automatically/scripted), let gvpack work on each, and finally putting the two sets in a single 1-row 2-column array (also with gvpack). But it seems a lot of trouble.

Any and all suggestions are welcome,


Recent comments