|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.primordion.xholon.io.AbstractChartViewer
org.primordion.xholon.io.ChartViewerJFreeChart
Captures data, and creates a chart using JFreeChart.
Data is captured in data structures at each time step, and the chart is prepared at the end of a run. JFreeChart is an open source project that can be freely downloaded from sourceforge.net/projects/jfreechart.
| Field Summary |
| Fields inherited from interface org.primordion.xholon.io.IChartViewer |
WRITE_AS_DOUBLE, WRITE_AS_FLOAT, WRITE_AS_INT, WRITE_AS_LONG, WRITE_AS_NULL, WRITE_AS_SHORT, WRITE_TIME_IN_HEADING |
| Constructor Summary | |
ChartViewerJFreeChart()
default constructor |
|
ChartViewerJFreeChart(IXholon chartRoot,
int nameConcatLevels)
constructor |
|
| Method Summary | |
void |
capture(double timeStep)
Capture data at each timestep. |
void |
capture(int numTimeSeries,
double xVal,
double[] yVal)
Capture specified data at each time interval. |
void |
chart()
Produce a chart from the captured data. |
void |
chart(boolean showLegend)
Produce a chart from the captured data. |
void |
createXySeries(int seriesCount,
java.lang.String[] seriesName)
Create one or more xy data series. |
void |
initialize(IXholon chartRoot,
int nameConcatLevels)
Initialize the chart viewer. |
void |
remove()
Remove the chart from the screen. |
| Methods inherited from class org.primordion.xholon.io.AbstractChartViewer |
setXRange, setYFormat, setYRange |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.primordion.xholon.io.IChartViewer |
setXRange, setYFormat, setYRange |
| Constructor Detail |
public ChartViewerJFreeChart()
public ChartViewerJFreeChart(IXholon chartRoot,
int nameConcatLevels)
chartRoot - JFreeChart node.| Method Detail |
public void initialize(IXholon chartRoot,
int nameConcatLevels)
initialize in interface IChartViewerchartRoot - XYChart node.nameConcatLevels - Number of composite levels to concatenate in deriving series name.
public void createXySeries(int seriesCount,
java.lang.String[] seriesName)
IChartViewer
createXySeries in interface IChartViewerseriesCount - Number of xy series.seriesName - Name of each xy series.public void capture(double timeStep)
IChartViewer
capture in interface IChartViewercapture in class AbstractChartViewer
public void capture(int numTimeSeries,
double xVal,
double[] yVal)
IChartViewer
capture in interface IChartViewercapture in class AbstractChartViewerpublic void chart()
IChartViewer
chart in interface IChartViewerchart in class AbstractChartViewerpublic void chart(boolean showLegend)
IChartViewer
chart in interface IChartViewershowLegend - Whether or not to show the legend. The legend shows the name and color of all data series.
If there are a lot of different series, then the legend can get too big.public void remove()
IChartViewer
remove in interface IChartViewerremove in class AbstractChartViewer
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||