In [1]:
%pylab --no-import-all inline


Populating the interactive namespace from numpy and matplotlib

In [3]:
import networkx as nx

In [4]:
G = nx.MultiGraph()

In [5]:
G.add_edges_from([(1, 2), (1, 2), (1, 3), (1, 4), (1, 4), (2, 3), (3, 4)])


Out[5]:
[0, 1, 0, 0, 1, 0, 0]

In [8]:
nx.draw_networkx(G)



In [9]:
G2 = nx.Graph()
G2.add_edges_from([(1, 2), (1, 3), (2, 3)])

In [10]:
nx.draw_circular(G2)


/Users/Arya/anaconda/lib/python3.5/site-packages/networkx/drawing/nx_pylab.py:125: MatplotlibDeprecationWarning: pyplot.hold is deprecated.
    Future behavior will be consistent with the long-time default:
    plot commands add elements without first clearing the
    Axes and/or Figure.
  b = plt.ishold()
/Users/Arya/anaconda/lib/python3.5/site-packages/networkx/drawing/nx_pylab.py:137: MatplotlibDeprecationWarning: pyplot.hold is deprecated.
    Future behavior will be consistent with the long-time default:
    plot commands add elements without first clearing the
    Axes and/or Figure.
  plt.hold(b)
/Users/Arya/anaconda/lib/python3.5/site-packages/matplotlib/__init__.py:917: UserWarning: axes.hold is deprecated. Please remove it from your matplotlibrc and/or style files.
  warnings.warn(self.msg_depr_set % key)
/Users/Arya/anaconda/lib/python3.5/site-packages/matplotlib/rcsetup.py:152: UserWarning: axes.hold is deprecated, will be removed in 3.0
  warnings.warn("axes.hold is deprecated, will be removed in 3.0")

In [ ]: