From: Jeff P. <jef...@se...> - 2005-07-07 16:44:58
|
Hello, I'm not sure I have the most efficient method for changing my plot settings. I have an application I wrote with maplotlib that allows a user to plot data and change different plot settings like color and line width etc. Initially when the program is created I create a default axes with no data plotted. The user then loads the data and presses a plot button. Once the data is plotted, each time the user changes the settings (for example they change the line color from red to blue) I call axes.clear(), then I call plot() again and this time I use the keywords to change the settings to (change the line color to blue) and then I call canvas.draw() to redraw the canvas. axes.clear() axes.plot(array,color=color, linestyle=pattern, linewidth=width, marker='None') canvas.draw() Is this the best way to do this? Thanks. Jeff |