PtPlot-5.10
Christopher Brooks, Edward A. Lee

Citation
Christopher Brooks, Edward A. Lee. "PtPlot-5.10". University of California, Berkeley, 26, January, 2015.

Abstract
Ptplot is a set of two dimensional signal plotters components written in Java with the following properties:

  • Embeddable in applets or applications.
  • Auto-ranging.
  • Automatic or manual labeling of axes.
  • Automatic or manual tick marks.
  • Logarithmic axes.
  • Live, animated plots.
  • Infinite zooming.
  • Various plot styles: connected lines, scatter plot, bars, etc.
  • Various point styles: none, dots, points, and unique marks.
  • Multiple data sets and a legend.
  • Color or black and white plotting.
  • Error bars.
  • Editable plots.
  • PlotML, and XML language for specifying plots.
  • Compatibility with pxgraph, an older plotting program.

There is a set of demonstrations of the various capabilities. There are several ways to use the classes in the plot package.

  • You can invoke an executable, ptplot, which is a shell script, to plot data on the local file system or on the network.
  • You can invoke an executable, pxgraph, which is a shell script, to plot data that is stored in binary format compatible with the older program pxgraph.
  • You can invoke a Java application, such as PlotMLApplication, by setting your CLASSPATH variable appropriately and using the java executable that is included in your Java distribution.
  • You can reference an existing applet class, such as PlotMLApplet, in an HTML file. The applet parameters, such as dataurl, give the plot data and format information, either by referring to another file on the network, or by directly including the information. You do not even have to have Ptplot installed on your server, since you can always reference the Berkeley installation.
  • You can create new classes derived from applet, frame, or application classes to customize your plots. This allows you to completely control the placement of plots on the screen, and to write Java code that defines the data to be plotted.

  • PlotML is an XML extension for plot data. Its syntax is similar to that of HTML.
  • An older, simpler syntax for plot data is also provided, although in the long term, that syntax is unlikely to be maintained (it will not necessarily be expanded to include new features). For simple data plots, however, it is adequate. Using it for applets has the advantage of making it possible to reference a slightly smaller jar file containing the code, which makes for more responsive applets.
  • A binary file format used by the popular pxgraph program, an extension of xgraph, is supported by classes in the compat package. There is also a shell script, called pxgraph, which invokes these classes. Formatting information in pxgraph (and in the compat package) is provided by command-line arguments, rather than being included with the plot data, exactly as in the older program. Applets specify these command-line arguments as an applet parameter.

Electronic downloads


Internal. This publication has been marked by the author for TerraSwarm-only distribution, so electronic downloads are not available without logging in.
Citation formats  
  • HTML
    Christopher Brooks, Edward A. Lee. <a
    href="http://www.terraswarm.org/pubs/479.html"
    ><i>PtPlot-5.10</i></a>, University of
    California, Berkeley, 26, January, 2015.
  • Plain text
    Christopher Brooks, Edward A. Lee. "PtPlot-5.10".
    University of California, Berkeley, 26, January, 2015.
  • BibTeX
    @software{BrooksLee15_PtPlot510,
        author = {Christopher Brooks and Edward A. Lee},
        title = {PtPlot-5.10},
        institution = {University of California, Berkeley},
        day = {26},
        month = {January},
        year = {2015},
        abstract = {Ptplot is a set of two dimensional signal plotters
                  components written in Java with the following
                  properties: <ul> <li> Embeddable in applets or
                  applications. <li> Auto-ranging. <li> Automatic or
                  manual labeling of axes. <li> Automatic or manual
                  tick marks. <li> Logarithmic axes. <li> Live,
                  animated plots. <li> Infinite zooming. <li>
                  Various plot styles: connected lines, scatter
                  plot, bars, etc. <li> Various point styles: none,
                  dots, points, and unique marks. <li> Multiple data
                  sets and a legend. <li> Color or black and white
                  plotting. <li> Error bars. <li> Editable plots.
                  <li> PlotML, and XML language for specifying
                  plots. <li> Compatibility with pxgraph, an older
                  plotting program. </ul> <p> There is a set of <a
                  href="http://ptolemy.eecs.berkeley.edu/java/ptplot5.10/ptolemy/plot/demo/">demonstrations</a>
                  of the various capabilities. There are several
                  ways to use the classes in the plot package. <ul>
                  <li> You can invoke an executable, <i>ptplot</i>,
                  which is a shell script, to plot data on the local
                  file system or on the network. <li> You can invoke
                  an executable, <i>pxgraph</i>, which is a shell
                  script, to plot data that is stored in binary
                  format compatible with the older program pxgraph.
                  <li> You can invoke a Java application, such as
                  PlotMLApplication, by setting your CLASSPATH
                  variable appropriately and using the
                  <code>java</code> executable that is included in
                  your Java distribution. <li> You can reference an
                  existing applet class, such as PlotMLApplet, in an
                  HTML file. The applet parameters, such as
                  <i>dataurl</i>, give the plot data and format
                  information, either by referring to another file
                  on the network, or by directly including the
                  information. You do not even have to have Ptplot
                  installed on your server, since you can always
                  reference the Berkeley installation. <li> You can
                  create new classes derived from applet, frame, or
                  application classes to customize your plots. This
                  allows you to completely control the placement of
                  plots on the screen, and to write Java code that
                  defines the data to be plotted. </ul> <p> <ul>
                  <li> PlotML is an XML extension for plot data. Its
                  syntax is similar to that of HTML. <li> An older,
                  simpler syntax for plot data is also provided,
                  although in the long term, that syntax is unlikely
                  to be maintained (it will not necessarily be
                  expanded to include new features). For simple data
                  plots, however, it is adequate. Using it for
                  applets has the advantage of making it possible to
                  reference a slightly smaller jar file containing
                  the code, which makes for more responsive applets.
                  <li> A binary file format used by the popular
                  pxgraph program, an extension of xgraph, is
                  supported by classes in the <i>compat</i> package.
                  There is also a shell script, called
                  <i>pxgraph</i>, which invokes these classes.
                  Formatting information in pxgraph (and in the
                  compat package) is provided by command-line
                  arguments, rather than being included with the
                  plot data, exactly as in the older program.
                  Applets specify these command-line arguments as an
                  applet parameter. </ul>},
        URL = {http://terraswarm.org/pubs/479.html}
    }
    

Posted by Christopher Brooks on 26 Jan 2015.
Groups: tools

Notice: This material is presented to ensure timely dissemination of scholarly and technical work. Copyright and all rights therein are retained by authors or by other copyright holders. All persons copying this information are expected to adhere to the terms and constraints invoked by each author's copyright.