History
HistoryCollapsingDiscard
public abstract class HistoryCollapsing extends java.lang.Object implements History
Modifier and Type | Field | Description |
---|---|---|
protected int |
cursor |
|
protected double[] |
history |
|
protected int |
interval |
|
protected int |
intervalCount |
|
protected int |
numCollapseBins |
|
protected double[] |
xValues |
Constructor | Description |
---|---|
HistoryCollapsing() |
|
HistoryCollapsing(int n) |
|
HistoryCollapsing(int nBins,
int nCollapseBins) |
Modifier and Type | Method | Description |
---|---|---|
protected abstract void |
collapseData() |
|
double[] |
getHistory() |
Returns the history
|
int |
getHistoryLength() |
Returns the number of data points tracked by the History.
|
int |
getNumCollapseBins() |
|
int |
getSampleCount() |
Returns the number of data samples currently held by the History.
|
double[] |
getXValues() |
Returns an array containing the x values that have been added to the
History.
|
void |
reset() |
Removes entire history, setting all values to NaN.
|
void |
setHistoryLength(int n) |
Sets the number of values kept in the history.
|
void |
setNumCollapseBins(int newNumCollapseBins) |
Sets the number of "collapse" bins.
|
protected double[] history
protected int cursor
protected double[] xValues
protected int interval
protected int intervalCount
protected int numCollapseBins
public HistoryCollapsing()
public HistoryCollapsing(int n)
public HistoryCollapsing(int nBins, int nCollapseBins)
public void setHistoryLength(int n)
setHistoryLength
in interface History
public int getHistoryLength()
History
getHistoryLength
in interface History
public int getSampleCount()
History
getSampleCount
in interface History
public void setNumCollapseBins(int newNumCollapseBins)
public int getNumCollapseBins()
public void reset()
public double[] getXValues()
History
getXValues
in interface History
protected abstract void collapseData()
public double[] getHistory()
getHistory
in interface History