python用networkx画图_Python+NetworkX画图的nx.draw_networkx(函数详解)

def draw_networkx(G, pos=None, arrows=True, with_labels=True, **kwds):

"""Draw the graph G using Matplotlib.

Draw the graph with Matplotlib with options for node positions,

labeling, titles, and many other drawing features.

See draw() for simple drawing without labels or axes.

Parameters

----------

G : graph

A networkx graph

pos : dictionary, optional

A dictionary with nodes as keys and positions as values.

If not specified a spring layout positioning will be computed.

See :py:mod:`networkx.drawing.layout` for functions that

compute node positions.

arrows : bool, optional (default=True)

For directed graphs, if True draw arrowheads.

Note: Arrows will be the same color as edges.

arrowstyle : str, optional (default='-|>')

For directed graphs, ch

你可能感兴趣的:(python用networkx画图_Python+NetworkX画图的nx.draw_networkx(函数详解))