title: Interaction between networkx and matplotlib
body: <p>I am trying networkx and visualization in matplotlib an I'm confused becouse I do not clearly understand how do they interact with each other?
  There simple example</p>
  
  <pre><code>import matplotlib.pyplot
  import networkx as nx
  G=nx.path_graph(8)
  nx.draw(G)
  matplotlib.pyplot.show()
  </code></pre>
  
  <p>Where do I tell pyplot, that I want to draw graph G?
  I guess  that nx.draw use something like matplotlib.pyplot.{plot, etc ...}
  So, if I want to draw 2 graphs:</p>
  
  <pre><code>import matplotlib.pyplot
  import networkx as nx
  
  G=nx.path_graph(8)
  E=nx.path_graph(30)
  nx.draw(G)
  
  matplotlib.pyplot.figure()
  nx.draw(E)
  matplotlib.pyplot.show()
  </code></pre>
  
  <p>Then... little experiment </p>
  
  <pre><code>import networkx as nx
  G=nx.path_graph(8)
  E=nx.path_graph(30)
  nx.draw(G)
  import matplotlib.pyplot
  matplotlib.pyplot.figure()
  nx.draw(E)
  import matplotlib.pyplot as plt
  plt.show()
  </code></pre>
  
  <p>Please don't kill me about this stupid code, I am just trying to understand - how do networkx draw something  matplotlib, while it even doesn't import yet!</p>
  
  <p>P.S: Sorry for my English.</p>