This, hopefully, is a simple question, but I cannot figure it out at the moment. I want to use matplotlib to show 2 digits and then use them interactively. I create numbers with:
import matplotlib import pylab as pl f1 = pl.figure() f2 = pl.figure()
and can use the MATLAB-like pyplot interface to build and draw both shapes. Via
current_figure = pl.gcf()
I can determine the current active digit for the pyplot interface, depending on which figure I clicked on. Now I want to draw something on the first digit with the pyplot interface, but the current digit can be any of them. So something like
pl.set_current_figure(figure)
or any workaround? (I know that I can use an object-oriented interface, but for interactive materials just using commands like plot (x, y) is much nicer)
python matplotlib
Alexander Nov 02 '11 at 19:57 2011-11-02 19:57
source share