
SSJ V. 2.6. 

PREV PACKAGE NEXT PACKAGE  FRAMES NO FRAMES 
See:
Description
Class Summary  

Axis  Represents an axis of a chart encapsulated by an instance of XYChart. 
BoxChart  This class provides tools to create and manage boxandwhisker plots. 
BoxSeriesCollection  This class stores data used in a
CategoryChart . 
CategoryChart  This class provides tools to create charts from data in a simple way. 
ContinuousDistChart  This class provides tools to plot the density and the cumulative probability of a continuous probability distribution. 
CustomHistogramDataset  A dataset that can be used for creating histograms. 
DiscreteDistIntChart  This class provides tools to plot the mass function and the cumulative probability of a discrete probability distribution over the integers. 
EmpiricalChart  This class provides additional tools to create and manage empirical plots. 
EmpiricalRenderer  A renderer that draws horizontal lines between points and/or draws shapes at each data point to provide an empirical style chart. 
EmpiricalSeriesCollection  Stores data used in a EmpiricalChart. 
HistogramChart  This class provides tools to create and manage histograms. 
HistogramSeriesCollection  Stores data used in a HistogramChart. 
MultipleDatasetChart  Provides tools to plot many datasets on the same chart. 
PlotFormat  Provide tools to import and export data set tables to and from Gnuplot, MATLAB and Mathematica compatible formats, or customized format. 
PPPlot  This class implements PPplot (or probabilityprobability plot) objects that compare two probability distributions. 
QQPlot  This class implements QQplot (or quantilequantile plot) objects that compare two probability distributions. 
ScatterChart  This class provides tools to create and manage scatter plots. 
SSJCategorySeriesCollection  Stores data used in a CategoryChart. 
SSJXYSeriesCollection  Stores data used in a XYChart. 
XYChart  This class provides tools to create charts from data in a simple way. 
XYLineChart  This class provides tools to create and manage curve plots. 
XYListSeriesCollection  This class extends
SSJXYSeriesCollection . 
YListChart  This class extends the class
XYLineChart . 
YListSeriesCollection  This class extends
XYListSeriesCollection . 
This package contains classes to produce charts used in the Java software developed in the simulation laboratory of the DIRO, at the Universite de Montreal. This package provides tools for easy construction, visualization, and customization of XY plots, histograms, and empirical styled charts from a Java program. It uses and extends the free and ``open source'' JFreeChart tool to manage the charts. JFreeChart is distributed under the terms of the GNU Lesser General Public License (LGPL), and can be found at http://www.jfree.org/jfreechart/.
This package also provides facilities to export charts to PGF/TikZ source code, which can be included into L^{A}TEX documents. TikZ is a free L^{A}TEX package to produce pictures such as plots, and can be downloaded from http://sourceforge.net/projects/pgf.
The user does not need to be familiar with the JFreeChart package or the TikZ syntax to use these tools, except if customization is required. For this, one may see the API specification of JFreeChart, and the reference manual of TikZ.
The two basic abstract classes of package charts are
XYChart
and
CategoryChart
. All other
charts inherit from one of these two. Charts are managed by
the mother class which contains the data tables in a
*SeriesCollection object, and the
information about xaxis and yaxis in
Axis
instances.
All these objects encapsulate JFreeChart instances along with some
additional TikZspecific attributes.
The method
view
displays charts on screen while the method
toLatex formats and returns a
String
which contains the TikZ source
code that can be written to a L^{A}TEX file.
Several chart styles are available and each one is represented by a
subclass of XYChart
or of
CategoryChart
.
The XYLineChart
uses
XYListSeriesCollection
to plot curves and lines, the
HistogramSeriesCollection
class is used by
HistogramChart
to plot
histograms, and the
EmpiricalSeriesCollection
is used by
EmpiricalChart
to plot empirical style charts. It is possible to draw a scatter plot or a box plot using
ScatterChart
or
BoxChart
respectively.
These concrete subclasses have similar APIs, but they are specialized for
different kinds of charts.
These charts can be customized using
*SeriesCollection subclasses and
Axis
.
First, one can use methods in
the XYChart
class for
setting the range values and a background grid.
One can also use the method
getSeriesCollection() for subclasses of charts to obtain
the dataset of the chart, which is represented by a
*SeriesCollection object.
This dataset can be customized in the following ways by calling
methods
on the series collection:
selecting color, changing
plot style (straight lines, curves, marks only, ...), putting marks
on points, setting a label and selecting the dash pattern (solid,
dotted, dashed, ...). The available properties depend on the type
of chart.
Moreover, objects representing the axes can be retrieved with
getXAxis
for the
xaxis, and
getYAxis
for the yaxis.
By using methods in Axis
,
many customizations are possible: setting a label to the axis,
setting ticks labels and values (auto ticks, periodical ticks or
manually defined ticks) and changing the twin axis position on the
current axis to select where axes must appear.
These settings are independent for each axis.
Each chart object from SSJ encapsulates a JFreeChart object: a
XYChart
instance contains a
JFreeChart instance from JFreeChart API, a
*SeriesCollection contains a
XYDataset and a XYItemRenderer, and finally an
Axis
contains a
NumberAxis. So any parameter proposed by
JFreeChart is reachable through
getter methods. However,
changing the JFreeChart parameters directly may have no impact
on the produced TikZ source code.
The two special classes
ContinuousDistChart
and
DiscreteDistIntChart
can be used to plot probability densities, mass functions,
and cumulative probabilities for continuous or discrete distributions,
which are implemented in package
probdist
of SSJ.
The package charts provides additional tools for formatting
data plot, and creating charts with multiple datasets. The
PlotFormat
class
offers basic tools to import and export data from files.
Supported file formats are GNUPlot and standard CSV, which is widely
used and accepted by most mathematical softwares such as
MATLAB and Mathematica. Customizing file input and output format is also possible.
Finally MultipleDatasetChart
provides tools to plot with different styles on the same chart.
For a series of examples, see the pdf documentation.

SSJ V. 2.6. 

PREV PACKAGE NEXT PACKAGE  FRAMES NO FRAMES 