|
From: Jeff W. <js...@fa...> - 2008-12-05 20:32:38
|
Mauro Cavalcanti wrote: > Dear ALL, > > Always engaged in pushing MPL/Basemap ahead of its limits, here am I > again with a humble question: I want to be able to toggle the display > of country boundaries on a map using a menu option on my wxPython > interface. It is quite easy to initially plotting a map without > borders and then toggling them on, but I could not figure out a way to > toggling them off (if possible, without redrawing the whole map). Is > there any trick to do this? ;-) > > Thanks in advance! > > With warmest regards, > > Mauro: The drawcountries() method returns a matplotlib line collection. Invoking the remove() method of the line collection will remove the countries from the axes instance. -Jeff -- Jeffrey S. Whitaker Phone : (303)497-6313 Meteorologist FAX : (303)497-6449 NOAA/OAR/PSD R/PSD1 Email : Jef...@no... 325 Broadway Office : Skaggs Research Cntr 1D-113 Boulder, CO, USA 80303-3328 Web : http://tinyurl.com/5telg |