When I am in an interactive python session (usually IPython), the following commands:
from matplotlib import pyplot as plt
plt.plot([1,2,3,4])
do not automatically raise a window, showing the plot. The only way I can make matplotlib actually raise the window is using show(), which also captures all input until I close the window destroying the plot. Now I have to give all my plot commands before I can see any result, which is a major nuisance. On OSX, I do not have this issue.
The backend I’m using is TkAgg. Using draw() and ion() calls has no effect.
If you use IPython pylab mode, this works:
there is not need for show() nor matplotlib import.
In IPython normal mode you can make your session interactive. This also works: