Content-Type: multipart/alternative; boundary=90e6ba6e8d8a6d3b7504a17580e1
--90e6ba6e8d8a6d3b7504a17580e1
Content-Type: text/plain; charset=ISO-8859-1
Hi Everyone,
I'm running into a problem with updating a plot that I've embedded into a Tk
application. I'm attaching the code with this email (so hopefully that will
show up at the end of the email). This is a very simple program, with one
canvas embedded into a window, with one menu and one button Tk widgets that
I'm using to select what plot type to display. The data are x, y, and t
variables, with x and y given by cos(2*pi*t) and sin(2*pi*t) respectively.
I'd like to be able to switch between a single scatter plot and two x(t) and
y(t) plots. The program "works" in that when you resize the window, the
plot updates, however, this really isn't ideal. I'd like the plot to
refresh when the button is clicked, and I can't seem to get it to work, nor
could I find support in previous email archives.
It seems like the trick used for animations, that is, only calling 'plot'
once and simply changing the xdata and ydata values of the line would speed
things up significantly, so I've implemented that in the code, but it
doesn't help.
Any help would be much appreciated! Thanks in advance.
Michael
--90e6ba6e8d8a6d3b7504a17580e1
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Hi Everyone,

I'm running into a problem with updating a plot tha=
t I've embedded into a Tk application.=A0 I'm attaching the code wi=
th this email (so hopefully that will show up at the end of the email).=A0 =
This is a very simple program, with one canvas embedded into a window, with=
one menu and one button Tk widgets that I'm using to select what plot =
type to display.=A0 The data are x, y, and t variables, with x and y given =
by cos(2*pi*t) and sin(2*pi*t) respectively.=A0 I'd like to be able to =
switch between a single scatter plot and two x(t) and y(t) plots.=A0 The pr=
ogram "works" in that when you resize the window, the plot update=
s, however, this really isn't ideal.=A0 I'd like the plot to refres=
h when the button is clicked, and I can't seem to get it to work, nor c=
ould I find support in previous email archives.

It seems like the trick used for animations, that is, only calling '=
;plot' once and simply changing the xdata and ydata values of the line =
would speed things up significantly, so I've implemented that in the co=
de, but it doesn't help.

Any help would be much appreciated!=A0 Thanks in advance.

Michae=
l

--90e6ba6e8d8a6d3b7504a17580e1--