Home | Trees | Indices | Help |
---|
|
Import and export networkx networks to dot format using pygraphviz.
Provides:
- write_dot()
- read_dot()
- graphviz_layout()
- pygraphviz_layout()
- to_pygraphviz()
- from_pygraphviz()
- xgraph_to_pygraphviz()
- xgraph_from_pygraphviz()
and the graph layout methods:
- graphviz_layout()
- pygraphviz_layout()
Does not currently handle graphviz subgraphs.
Either this module or nx_pydot can be used to interface with graphviz.
Date: $Date: 2005-06-15 08:55:33 -0600 (Wed, 15 Jun 2005) $
Author: Aric Hagberg (hagberg@lanl.gov)
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|
|||
__credits__ =
|
|||
__revision__ =
|
|
Write NetworkX graph G to Graphviz dot format on path. Path can be a string or a file handle. |
Return a NetworkX Graph from a dot file on path. Path can be a string or a file handle. |
Creates a pygraphviz graph from an networkx graph N. This simplest use creates a pygraphviz graph with no attributes, just the nodes and edges. Attributes can be added by modifying the resulting pygraphviz graph. Optional arguments graph_attr, node_attr, edge_attr are used to specify Graphviz graph properties to applied during the conversion. http://www.graphviz.org/doc/info/attrs.html The graph_attr, node_attr, and edge_attr arguments can be either a dictionary or function as follows:
|
Creates an networkx graph from an pygraphviz graph A. This simplest use creates a netwrkx graph and ignores graphviz attributes. Optional arguments graph_attr, node_attr, edge_attr are used to get graph properties. http://www.graphviz.org/doc/info/attrs.html The graph_attr, node_attr, and edge_attr arguments can be either a dictionary or function as follows:
create_using is an optional networkx graph type. The default is to use a Graph or DiGraph depending on the type of the pygraphviz graph A |
Creates an networkx graph from an pygraphviz graph A. This simplest use creates a netwrkx graph and ignores graphviz attributes. Optional arguments graph_attr, node_attr, edge_attr are used to get graph properties. http://www.graphviz.org/doc/info/attrs.html The graph_attr, node_attr, and edge_attr arguments can be either a dictionary or function as follows:
create_using is an optional networkx graph type. The default is to use a Graph or DiGraph depending on the type of the pygraphviz graph A |
Creates a pygraphviz graph from an networkx graph N. This simplest use creates a pygraphviz graph with no attributes, just the nodes and edges. Attributes can be added by modifying the resulting pygraphviz graph. Optional arguments graph_attr, node_attr, edge_attr are used to specify Graphviz graph properties to applied during the conversion. http://www.graphviz.org/doc/info/attrs.html The graph_attr, node_attr, and edge_attr arguments can be either a dictionary or function as follows:
|
Convert from a pygraphviz graph to a NetworkX XGraph. A NetworkX XGraph XG is returned with XG.attr - a dictionary set to the graphviz graph attributes XG.nattr - a dictionary keyed by node with graphviz graph attributes and the edge data set to a dictionary of graphviz edge attributes. |
|
Create layout using graphviz. Returns a dictionary of positions keyed by node. >>> from networkx import * >>> G=petersen_graph() >>> pos=graphviz_layout(G) >>> pos=graphviz_layout(G,prog='dot') This is a wrapper for pygraphviz_layout. |
Create layout using pygraphviz and graphviz. Returns a dictionary of positions keyed by node. >>> from networkx import * >>> G=petersen_graph() >>> pos=pygraphviz_layout(G) >>> pos=pygraphviz_layout(G,prog='dot') |
Home | Trees | Indices | Help |
---|
Generated by Epydoc 3.0beta1 on Sun Aug 17 12:04:43 2008 | http://epydoc.sourceforge.net |