I have a sizeable number of python data-inspection scripts that work as
follows:

- read some data, or do something with it
- plot the data
- query the user on the command line and get a response
- do what the user commands.

These use the venerable PGPLOT package for the graphics, but this has been
static for years and is getting increasingly vulnerable to obsolescence of
the supporting packages (e.g., numarray).

I'm having a hard time converting these scripts to matplotlib because when
you do a show(), the mainloop takes over.  It's possible to work around by
doing a show() for every plot, and then killing the plot manually, but after
a couple of hundred manual kills this gets tiresome.  It would also be
possible to restructure the code so that the various options get controlled
by key press events in the plot, I suppose, but the effort involved in
converting all the scripts would be pretty large.

So my question:  Is there a simple way of getting matplotlib to display a
plot in a window and then surrender control to the main program, without
destroying the plot?  Something like a method to kill mainloop would be
ideal.  

Thanks.

[Apologies if this is general knowledge -- I couldn't find an answer.]
-- 
View this message in context: 
http://old.nabble.com/Non-interactive-plotting-to-window--tp32981792p32981792.html
Sent from the matplotlib - users mailing list archive at Nabble.com.


------------------------------------------------------------------------------
10 Tips for Better Server Consolidation
Server virtualization is being driven by many needs.  
But none more important than the need to reduce IT complexity 
while improving strategic productivity.  Learn More! 
http://www.accelacomm.com/jaw/sdnl/114/51507609/
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users

Reply via email to