Instructions and links to source code are at the bottom.
The applet loads data from a text file specified in the the html code with a param tag within the applet tag like this:
<applet
code=diagapplet.plotter.dplotter.class
id=dplotter
width=600
height=300 >
<param name=url value="http://www.isd.mel.nist.gov/projects/rcs_lib/diagapplet/plotter/sineonly.txt">
</applet>
You may also want to add:
archive="plotter.jar"
To make the applet load the class files from within a cab or jar archive.
The text file can also supply options for choosing line widths, colors etc for how the graph should be displayed. To see the text that was loaded choose the "Text" option in the Choice control in the upper right corner of the applet or click here sineonly.txt. You can also create your own graphs by editing the text in the text area displayed.
If you have more than one plot on the screen you may want to switch to the key screen by using the Choice control in the upper right of the applet.
To put this applet on another web site. You will need to download one of the following archives and extract the files from it.:
NOTE: plotter.cab contains somewhat older code that is not easily updated.
The class dplotter is in package diagapplet.plotter. Since java packages correspond to sub-directories. Directory locations are important and somewhat counter-intuitive.
For example if after untarring and compiling if necessary the file dplotter.class ended up in /users/yourlogin/java_classes/diagapplet/plotter then you would want to put HTML files with the above <applet> tag in /users/yourlogin/java_classes intstead of in /users/yourlogin/java_classes/diagapplet/plotter. If your compiling or using the java application loader you would also want to set CLASSPATH to /users/yourlogin/java_classes.
If you get plotter.jar and the JDK it may be convenient to run the applet with a command like this:
java -cp plotter.jar diagapplet.plotter.dplotter URL=sineonly.txt
If you have any questions or comments regarding this page please direct them to
shackle@nist.gov .DISCLAIMER: This software was produced by the National Institute of Standards and Technology (NIST), an agency of the U.S. government, and by statute is not subject to copyright in the United States. Recipients of this software assume all responsibility associated with its operation, modification, maintenance, and subsequent redistribution.