Limits to graph coordinates

Hi guys,

I'm using grappa and graphviz dot to generate new graphs.

The dot does a great job putting the nodes in the right place but now, I need to create limits in the coordinates generated.

For example it places the nodes in coordinates like (0,0), (450,200)...

I want is dot places nodes in the coordinate range (-180,-90)(180,90)

It is possible in attributes give this range to Dot?

Best regards

Limits to graph coordinates

The dot algorithm does not support a notion of layout within a given box. In particular, once the nodes are placed on levels, the width of a rank is bounded below by the sum of the widths of the nodes on that rank, and the graph will have to be at least this wide. Using ratio=compress or aspect=1 may help but with no guarantees. You can also decrease the size by adjusting the nodesep and ranksep attributes.

If you just need a simple translation, that can be done using gvpr or something similar.

Recent comments