AnyLogic AnyLogic
Expand
Font size
All Implemented Interfaces:
java.io.Serializable

public class HistogramSmartData
extends HistogramData
Data of a histogram with a fixed number of intervals but auto-adjustable data range. The data range covered by the intervals always includes the full range of data samples added.
Author:
AnyLogic North America, LLC https://anylogic.com
See Also:
Serialized Form

Constructor Summary

Constructors 
HistogramSmartData​(int nIntervals, double initialIntervalWidth, boolean calcCDF, boolean calcPercentiles, double lowPercent, double highPercent)
Constructs a smart histogram data object with the given number of intervals and initial interval width.
HistogramSmartData​(int nIntervals, double initialIntervalWidth, boolean calcCDF, boolean calcPercentiles, double lowPercent, double highPercent, DataUpdater_xjal updater)
Constructs a smart histogram data object with the given number of intervals and initial interval width.
Constructor Description

Method Summary

All Methods Instance Methods Concrete Methods 
void add​(double val)
Adds a sample data item to the histogram data object.
double getIntervalWidth()
Returns the current interval width, i.e. the data range corresponding to one interval.
double getLowerBound()
Returns the lower bound of the range covered by intervals.
double getXMax()
Returns the upper bound of the range covered by intervals.
double getXMin()
Returns the lower bound of the range covered by intervals.
void reset()
Fully resets the histogram data object: discards all PDF/CDF data and statistics; also restores the initial interval width.
Modifier and Type Method Description

Methods inherited from class com.anylogic.engine.analysis.HistogramData

arePercentilesEnabled, count, destroyUpdater_xjal, deviation, getCDF, getMaxPDF, getNumberOfIntervals, getPDF, getPercentHigh, getPercentLow, getPlainDataTable, getStatistics, isCDFEnabled, max, mean, meanConfidence, min, setCDFEnabled, setPercentilesEnabled, setPercents, toString, update

Methods inherited from class com.anylogic.engine.analysis.ChartItem

getVersion

Methods inherited from class java.lang.Object

equals, getClass, hashCode, notify, notifyAll, wait, wait, wait

Constructor Detail

HistogramSmartData

public HistogramSmartData​(int nIntervals,
                          double initialIntervalWidth,
                          boolean calcCDF,
                          boolean calcPercentiles,
                          double lowPercent,
                          double highPercent)
Constructs a smart histogram data object with the given number of intervals and initial interval width.
Parameters:
nIntervals - the number of intervals
initialIntervalWidth - the initial data range corresponding to one interval
calcCDF - if true, CDF is calculated
calcPercentiles - if true and calcCDF is true, percentiles are calculated
lowPercent - the low percent bound
highPercent - the high percent bound

HistogramSmartData

public HistogramSmartData​(int nIntervals,
                          double initialIntervalWidth,
                          boolean calcCDF,
                          boolean calcPercentiles,
                          double lowPercent,
                          double highPercent,
                          DataUpdater_xjal updater)
Constructs a smart histogram data object with the given number of intervals and initial interval width.
Parameters:
nIntervals - the number of intervals
initialIntervalWidth - the initial data range corresponding to one interval
calcCDF - if true, CDF is calculated
calcPercentiles - if true and calcCDF is true, percentiles are calculated
lowPercent - the low percent bound
highPercent - the high percent bound
updater - updater which may be used instead of overriding HistogramData.update() method

Method Detail

reset

public void reset()
Fully resets the histogram data object: discards all PDF/CDF data and statistics; also restores the initial interval width.
Overrides:
reset in class HistogramData

add

public void add​(double val)
Adds a sample data item to the histogram data object.
Specified by:
add in class HistogramData
Parameters:
val - the sample value

getIntervalWidth

public double getIntervalWidth()
Returns the current interval width, i.e. the data range corresponding to one interval.
Overrides:
getIntervalWidth in class HistogramData
Returns:
the current interval width

getLowerBound

public double getLowerBound()
Returns the lower bound of the range covered by intervals. It is less or equal to the minimum of all data samples.
Returns:
the lower bound of the range covered by intervals

getXMin

public double getXMin()
Returns the lower bound of the range covered by intervals.
Specified by:
getXMin in class HistogramData
Returns:
the lower bound of the range covered by intervals

getXMax

public double getXMax()
Returns the upper bound of the range covered by intervals.
Specified by:
getXMax in class HistogramData
Returns:
the upper bound of the range covered by intervals
How can we improve this article?