dino wrote: > I posted this to the sage-newbie list, but it never generated a > response. I understand this list has > more people "in the know." > > We have the following snippet: > > arm = animate([arrow((0,0),(cos(i), sin(i)), > rgbcolor=(1,0,1)) > for i in srange(0, 2*pi, 0.3)]) > arm.show() > > It generates a rotating arrow. I wish to generate an animated line, > but the obvious substitution fails, generating a graph but no line. > Fiddling with the code in other ways also fails. >
sage: arm = animate([line([(0,0),(cos(i), sin(i))], rgbcolor=(1,0,1)) for i in srange(0, 2*pi, 0.3)]) sage: arm.show() seems to work. Note that line() takes a *list* of points, not just two points as two separate parameters, so it is [(0,0), (cos(i), sin(i))]. Jason --~--~---------~--~----~------------~-------~--~----~ To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sage-support URLs: http://www.sagemath.org -~----------~----~----~----~------~----~------~--~---