|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.commons.math.stat.DescriptiveStatistics
org.apache.commons.math.stat.AbstractStorelessDescriptiveStatistics
Provides univariate measures for an array of doubles.
Field Summary | |
protected GeometricMean |
geoMean
geoMean of values that have been added |
protected Kurtosis |
kurtosis
kurtosis of values that have been added |
protected Max |
max
max of values that have been added |
protected Mean |
mean
mean of values that have been added |
protected Min |
min
min of values that have been added |
protected FourthMoment |
moment
FourthMoment is used in calculating mean, variance,skew and kurtosis |
protected int |
n
count of values that have been added |
protected Skewness |
skewness
skewness of values that have been added |
protected Sum |
sum
sum of values that have been added |
protected SumOfLogs |
sumLog
sumLog of values that have been added |
protected SumOfSquares |
sumsq
sum of the square of each value that has been added |
protected Variance |
variance
variance of values that have been added |
protected int |
windowSize
hold the window size |
Fields inherited from class org.apache.commons.math.stat.DescriptiveStatistics |
INFINITE_WINDOW, LEPTOKURTIC, MESOKURTIC, PLATYKURTIC |
Constructor Summary | |
AbstractStorelessDescriptiveStatistics()
Construct an AbstractStorelessDescriptiveStatistics |
|
AbstractStorelessDescriptiveStatistics(int window)
Construct an AbstractStorelessDescriptiveStatistics with a window |
Method Summary | |
abstract void |
addValue(double value)
If windowSize is set to Infinite, statistics are calculated using the following recursive strategy . |
abstract double |
apply(UnivariateStatistic stat)
Apply the given statistic to this univariate collection. |
void |
clear()
Resets all statistics and storage |
double |
getGeometricMean()
Returns the geometric mean of the available values |
double |
getKurtosis()
Returns the kurtosis of the values that have been added as described by Equation (7) for k-Statistics. |
int |
getKurtosisClass()
Returns the Kurtosis "classification" a distribution can be leptokurtic (high peak), platykurtic (flat peak), or mesokurtic (zero kurtosis). |
double |
getMax()
Returns the maximum of the available values |
double |
getMean()
Returns the arithmetic mean of the available values |
double |
getMin()
Returns the minimum of the available values |
int |
getN()
Returns the number of available values |
double |
getSkewness()
Returns the skewness of the values that have been added as described by Equation (6) for k-Statistics. |
double |
getStandardDeviation()
Returns the standard deviation for this collection of values |
double |
getSum()
Returns the sum of the values that have been added to Univariate. |
double |
getSumsq()
Returns the sum of the squares of the available values. |
double |
getVariance()
Returns the variance of the values that have been added via West's algorithm as described by Chan, T. |
int |
getWindowSize()
Univariate has the ability to return only measures for the last N elements added to the set of values. |
void |
setWindowSize(int windowSize)
WindowSize controls the number of values which contribute to the values returned by Univariate. |
String |
toString()
Generates a text report displaying univariate statistics from values that have been added. |
Methods inherited from class org.apache.commons.math.stat.DescriptiveStatistics |
getElement, getPercentile, getSortedValues, getValues, newInstance, newInstance, newInstance |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
protected int windowSize
protected int n
protected FourthMoment moment
protected Sum sum
protected SumOfSquares sumsq
protected Min min
protected Max max
protected SumOfLogs sumLog
protected GeometricMean geoMean
protected Mean mean
protected Variance variance
protected Skewness skewness
protected Kurtosis kurtosis
Constructor Detail |
public AbstractStorelessDescriptiveStatistics()
public AbstractStorelessDescriptiveStatistics(int window)
window
- The Window SizeMethod Detail |
public abstract double apply(UnivariateStatistic stat)
stat
- the statistic to apply
public abstract void addValue(double value)
addValue
in class DescriptiveStatistics
value
- the value to be addedorg.apache.commons.math.stat.Univariate#addValue(double)
public int getN()
DescriptiveStatistics
getN
in class DescriptiveStatistics
org.apache.commons.math.stat.Univariate#getN()
public double getSum()
DescriptiveStatistics
getSum
in class DescriptiveStatistics
org.apache.commons.math.stat.Univariate#getSum()
public double getSumsq()
DescriptiveStatistics
getSumsq
in class DescriptiveStatistics
org.apache.commons.math.stat.Univariate#getSumsq()
public double getMean()
DescriptiveStatistics
getMean
in class DescriptiveStatistics
org.apache.commons.math.stat.Univariate#getMean()
public double getStandardDeviation()
getStandardDeviation
in class DescriptiveStatistics
org.apache.commons.math.stat.Univariate#getStandardDeviation()
public double getVariance()
getVariance
in class DescriptiveStatistics
public double getSkewness()
getSkewness
in class DescriptiveStatistics
public double getKurtosis()
getKurtosis
in class DescriptiveStatistics
public int getKurtosisClass()
DescriptiveStatistics
getKurtosisClass
in class DescriptiveStatistics
DescriptiveStatistics.getKurtosisClass()
public double getMax()
DescriptiveStatistics
getMax
in class DescriptiveStatistics
org.apache.commons.math.stat.Univariate#getMax()
public double getMin()
DescriptiveStatistics
getMin
in class DescriptiveStatistics
org.apache.commons.math.stat.Univariate#getMin()
public double getGeometricMean()
DescriptiveStatistics
getGeometricMean
in class DescriptiveStatistics
org.apache.commons.math.stat.Univariate#getGeometricMean()
public String toString()
public void clear()
DescriptiveStatistics
clear
in class DescriptiveStatistics
org.apache.commons.math.stat.Univariate#clear()
public int getWindowSize()
DescriptiveStatistics
getWindowSize
in class DescriptiveStatistics
org.apache.commons.math.stat.Univariate#getWindowSize()
public void setWindowSize(int windowSize)
DescriptiveStatistics
setWindowSize
in class DescriptiveStatistics
windowSize
- sets the size of the window.org.apache.commons.math.stat.Univariate#setWindowSize(int)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |