I am a newbie of matplotlib.
Recently I am using #WinPython-64bit-3.3.2.1# on #Win-7 64bit# and When I typed codes on the IPython Qt Control as below:
In [1]: plot(range(3))
Out[1]: [<.matplotlib.lines.Line2D at 0x64ae390>]
% There is a plot.
In [2]: show()
%nothing happened.
There should be a plot after show. But nothing happed, no error message. And the savefig() will only save a blank fig. I tried the solution of matplotlib does not show my drawings although I call pyplot.show() by setting backends = 'GtkAgg' or 'QtAgg', but it did not work.
Thanks for your advice. :)
Updata1: The 'WinPython Interpreter.exe' is used instead of 'IPython QT Console.exe'. Then I typed the same code and the
show()
worked. The backend is set toGtkAgg
.I think the reason is as below:
Since WinPythonInterpreter is a command window, it need a new window to display the plot. The IPython supports interactive data visualization, it does not need another window.
Updata2: I just fount that the
gcf()
returned different references in the QT Console, and it returned the same reference in WinPython Interpreter. Maybe this is the problem point.