I used to work with python 2.2 and with that version I was able to
make multiple plots in one script like the example below:
from pylab import *
x = arange(10)
plot(x, c = 'b')
plot(x, c = 'r')
plot(x[::-1], c = 'g')
The script would stop running during the visualisation of the plot
and continue after I manually closed the plotting window.
However, with the newest python (2.4.1) and matplotlib.pylab version
0.83.2, only the first window can be closed manually. Python then
goes into interactive mode and all the plotting commands are plotted
into one new window, which can not be accessed anymore by windows,
the window hangs.
How can I make make multiple plots within one script using the newest
From: Alan G Isaac <aisaac@am...> - 2005-08-26 01:20:44
On Thu, 25 Aug 2005, Menno Straatsma apparently wrote:
> How can I make make multiple plots within one script using
> the newest python version?
The short answer is:
give the fig() command before starting to create each plot,
and give only one show() command at the end.
However all plots will be displayed when you give the show
command. Like you, I used to use multiple show() commands
in order to get sequential (one at a time) display. I found
this useful in the classroom. I do not know how to do that
in pylab now.
Get latest updates about Open Source Projects, Conferences and News.