plt.show() and plt.draw() doesnt work
I have a numpy array M. I generate a graph using NetworkX and then I want to draw this graph:
import networkx as nx import matplotlib.pyplot as plt G=nx.Graph(M) nx.draw(G) plt.draw()
Doing this, no picture appears. In addition, if I do
plt.show() no picture appears neither.
If I do
import numpy as np import matplotlib.pyplot as plt x = np.range(0, 5, 0.1); y = np.sin(x) plt.plot(x, y)
no picture appears neither.