Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

a functional java applet for 2d plots

3d plotting with jmol is great idea. However, all what I find for 2d plotting generates a picture only. I'd like to have an applet for that which supports cursors, zooming, maybe hiding certain plotted lines and other interactive control elements. Of course, this can be somehow done with @interact, but the applet would work much faster than the link browser-worksheet-sage. At least, an attempt to introduce cursor did not seem to have a handy result:

p1=plot (sin(x))
def _(b = slider(-1, 1, 0.01, default=0.5, label='cursor')):
   p2=line(((b,-1),(b,1)), color='green')

Does anybody know if there is an easy way to do this, or if there is not, where one may start integrating such an applet into sage? There are a number of open-source graphing applets. Here is the example, maybe, even not the best one.