From: Matt N. <new...@ca...> - 2005-03-07 17:34:50
|
Hi Andrea, The pylab interface is generally the non-Class-based approached, suitable for small, procedural scripts. Personally, I'd say this is good for interactive use, 'one-time' scripts, and very simple uses of matplotlib, but that's just my opinion: it seems many people use pylab for more demanding apps. But: you don't need to import pylab at all if you're creating a matplotlib figure in a wxPython (or other) GUI. And, for me at least, toggling the grid and interacting with gui Events work fine. If the embedding_in_wx*.py and the docs aren't enough, you may find it useful to look at the wxPython plotting widget (MPlot) I've been working on. The code is currently at http://cars.uchicago.edu/~newville/Epics/Python/MPlot This provides a simple wxPython Panel (and/or Frame) widget that has simple plot() and oplot() methods. This widget responds to events for zoom, etc and several of the plot attributes (title, labels, line symbol/color,etc) can be altered through the GUI, and you can export plot images and/or use the Printer interface. The documentation is scant but there are a couple examples and a README. I'm intending to improve the functionality and docs and have at least one other person interested and helping out on this. Anyway, feel free to steal from this (that goes for anyone else on the list as well!!). Any suggestions for improvement would be great. Cheers, --Matt |