networkx/networkx — pull request #812 by chebee7i (2013-01-08 09:11:23+00:00)
Title: Drawing with pydot/Graphviz and inline IPython displays

NetworkX is primarily a graph analysis tool and not a graph visualization tool. However, people (myself included) continue to use NetworkX's graph drawing features. There have been past proposals on how we might be able to provide "nicer" looking drawings (esp for directed graphs), but progress has been slow.

Graphviz is ubiquitous and provides a quick, flexible visualization solution. The idea is to draw graphs using Graphviz and then display them using the OS's default viewer. This is a "non-Python" solution, but it works. We already have nx.view_pygraphviz(), but I suspect its rarely used. And Pygraphviz on Windows is problematic enough.

In this pull request, I've revamped the pydot conversions and added a new function: nx.draw_pydot(). This function converts NetworkX graphs to the pydot graph, draws the graphs externally using graphviz, and then displays the graph. Additionally, one can display the graphs inline within an IPython Notebook.

My hope is that this quick and dirty solution will serve as a nice band-aid until we get something more Pythonic.

![Screenshot](https://f.cloud.github.com/assets/326005/49633/cff48e76-5971-11e2-9d1c-70a49cea9699.png)