SSJ  3.3.1
Stochastic Simulation in Java
Public Member Functions | Package Attributes | List of all members
BoxSeriesCollection Class Reference

This class stores data used in a umontreal.ssj.charts.CategoryChart. More...

Inheritance diagram for BoxSeriesCollection:
[legend]
Collaboration diagram for BoxSeriesCollection:
[legend]

Public Member Functions

 BoxSeriesCollection ()
 Creates a new BoxSeriesCollection instance with an empty dataset.
 
 BoxSeriesCollection (double[] data, int numPoints)
 Creates a new BoxSeriesCollection instance with default parameters and input series data. More...
 
 BoxSeriesCollection (double[]... data)
 Creates a new BoxSeriesCollection instance with default parameters and given data series. More...
 
 BoxSeriesCollection (DefaultBoxAndWhiskerCategoryDataset data)
 Creates a new BoxSeriesCollection instance with default parameters and given data series. More...
 
Data control methods
int add (double[] data)
 Adds a data series into the series collection. More...
 
int add (double[] data, int numPoints)
 Adds a data series into the series collection. More...
 
String getName (int series)
 Gets the current name of the selected series. More...
 
double [] getRangeBounds ()
 Returns the range ( \(y\)-coordinates) min and max values. More...
 
String toString ()
 Returns in a String all data contained in the current object. More...
 
String toLatex (double YScale, double YShift, double ymin, double ymax)
 NOT IMPLEMENTED: To do. More...
 
- Public Member Functions inherited from SSJCategorySeriesCollection
String getCategory (int series)
 Returns the category-value in the specified series. More...
 
double getValue (int series, int index)
 Returns the \(y\)-value at the specified index in the specified series. More...
 
CategoryDataset getSeriesCollection ()
 Returns the CategoryDataset object associated with the current object. More...
 
abstract double [] getRangeBounds ()
 Returns range ( \(y\)-coordinates) min and max values. More...
 
abstract String toString ()
 Returns in a String all data contained in the current object. More...
 
CategoryItemRenderer getRenderer ()
 Returns the CategoryItemRenderer object associated with the current object. More...
 
void setRenderer (CategoryItemRenderer renderer)
 Sets the CategoryItemRenderer object associated with the current variable. More...
 
Color getColor (int series)
 Gets the current plotting color of the selected series. More...
 
void setColor (int series, Color color)
 Sets a new plotting color to the series \(series\). More...
 
abstract String toLatex (double YScale, double YShift, double ymin, double ymax)
 Formats and returns a string containing a LaTeX-compatible source code which represents this data series collection. More...
 

Package Attributes

final double BARWIDTH = 0.1
 

Additional Inherited Members

- Static Protected Member Functions inherited from SSJCategorySeriesCollection
static String detectXColorClassic (Color color)
 Converts a java Color object into a friendly and readable LaTeX/xcolor string. More...
 
static Color getDefaultColor (int index)
 Gives the default color associated with a series. More...
 
static double max (double[] t)
 
static double min (double[] t)
 
- Protected Attributes inherited from SSJCategorySeriesCollection
CategoryItemRenderer renderer
 
CategoryDataset seriesCollection
 

Detailed Description

This class stores data used in a umontreal.ssj.charts.CategoryChart.

It also provides complementary tools to draw box-and-whisker plots; for example, one may add or remove plots series and modify plot style. This class is linked with the JFreeChart DefaultBoxAndWhiskerCategoryDataset class to store data plots, and linked with the JFreeChart BoxAndWhiskerRenderer to render the plots.

Constructor & Destructor Documentation

◆ BoxSeriesCollection() [1/3]

BoxSeriesCollection ( double []  data,
int  numPoints 
)

Creates a new BoxSeriesCollection instance with default parameters and input series data.

Only the first numPoints of data will taken into account.

Parameters
datapoint sets.
numPointsNumber of points

◆ BoxSeriesCollection() [2/3]

BoxSeriesCollection ( double... []  data)

Creates a new BoxSeriesCollection instance with default parameters and given data series.

The input parameter represents series of point sets.

Parameters
dataseries of point sets.

◆ BoxSeriesCollection() [3/3]

BoxSeriesCollection ( DefaultBoxAndWhiskerCategoryDataset  data)

Creates a new BoxSeriesCollection instance with default parameters and given data series.

The input parameter represents a DefaultBoxAndWhiskerCategoryDataset.

Parameters
dataseries of point sets.

Member Function Documentation

◆ add() [1/2]

int add ( double []  data)

Adds a data series into the series collection.

Vector data represents a point set.

Parameters
datapoint sets.
Returns
Integer that represent the new point set’s position in the JFreeChart DefaultBoxAndWhiskerXYDataset object.

◆ add() [2/2]

int add ( double []  data,
int  numPoints 
)

Adds a data series into the series collection.

Vector data represents a point set. Only the first numPoints of data will be added to the new series.

Parameters
dataPoint set
numPointsNumber of points to add
Returns
Integer that represent the new point set’s position in the JFreeChart DefaultBoxAndWhiskerXYDataset object.

◆ getName()

String getName ( int  series)

Gets the current name of the selected series.

Parameters
seriesseries index.
Returns
current name of the series.

◆ getRangeBounds()

double [] getRangeBounds ( )

Returns the range ( \(y\)-coordinates) min and max values.

Returns
range min and max values.

◆ toLatex()

String toLatex ( double  YScale,
double  YShift,
double  ymin,
double  ymax 
)

NOT IMPLEMENTED: To do.

Parameters
ymin
ymax
Returns
LaTeX source code

◆ toString()

String toString ( )

Returns in a String all data contained in the current object.

Returns
All data contained in the current object as a String.

The documentation for this class was generated from the following file: