http://qs321.pair.com?node_id=558233


in reply to How to print/draw a network graph

I second blokhead's recommendation of Graphviz. In case you haven't found them already, CPAN hosts Graphviz and Tk::Graphviz, which (as far as my limited understanding goes) provide Perl wrappers around the Graphviz executables.

Graphviz enables you to create charts as Perl data-structures and then render them using the (extensive) Graphviz options.

Tk::Graphviz takes output from the Graphviz binaries and renders them as a Tk::Canvas object; it doesn't support all the formatting options of using the binaries, but does enable you to access the chart interactively using a callback when a node is clicked, which I found handy to access additional node information stored in a database. It accepts a filename, a scalar string or a Tk::Graphviz object as input.