PyGraphviz: Difference between revisions

From XPUB & Lens-Based wiki
No edit summary
No edit summary
Line 11: Line 11:


See [[Graphviz]]
See [[Graphviz]]
== Resources ==
* [www.graphviz.org/doc/info/attrs.html Node Attributes]


[[Category: Cookbook]] [[Category: Python]]
[[Category: Cookbook]] [[Category: Python]]

Revision as of 11:13, 31 October 2011

http://networkx.lanl.gov/pygraphviz/

import pygraphviz as pgv

g = pgv.AGraph()
g.add_node(nn, label=label.encode("utf-8"), shape="box", URL=rdfnode(row['doc']))
g.add_edge(nn, onn)
g.draw(path="output.svg", format="svg", prog="fdp")

See Graphviz

Resources

  • [www.graphviz.org/doc/info/attrs.html Node Attributes]