class NumericStatsValues extends AbstractStatsValues<java.lang.Number>
| Modifier and Type | Field and Description |
|---|---|
(package private) double |
sum |
(package private) double |
sumOfSquares |
| Constructor and Description |
|---|
NumericStatsValues(FieldType fieldType) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
addTypeSpecificStats(NamedList<java.lang.Object> res)
Adds sum, sumOfSquares, mean and standard deviation statistics to the given NamedList
|
private double |
getStandardDeviation()
Calculates the standard deviation statistic
|
protected java.lang.Double |
toTypedValue(java.lang.String value)
Converts the String value to a value associated with the specific StatsValues implementation
|
protected void |
updateMinMax(java.lang.Number min,
java.lang.Number max)
Updates the minimum and maximum statistics based on the given values
|
void |
updateTypeSpecificStats(NamedList stv)
Updates the type specific statistics based on the values in the given list
|
void |
updateTypeSpecificStats(java.lang.Number v)
Updates the type specific statistics based on the given value
|
void |
updateTypeSpecificStats(java.lang.Number v,
int count)
Updates the type specific statistics based on the given value
|
accumulate, accumulate, accumulate, addFacet, addMissing, getStatsValues, missingpublic NumericStatsValues(FieldType fieldType)
public void updateTypeSpecificStats(NamedList stv)
updateTypeSpecificStats in class AbstractStatsValues<java.lang.Number>stv - List containing values the current statistics should be updated againstpublic void updateTypeSpecificStats(java.lang.Number v)
updateTypeSpecificStats in class AbstractStatsValues<java.lang.Number>v - Value the statistics should be updated againstpublic void updateTypeSpecificStats(java.lang.Number v,
int count)
updateTypeSpecificStats in class AbstractStatsValues<java.lang.Number>v - Value the statistics should be updated againstcount - Number of times the value is being accumulatedprotected void updateMinMax(java.lang.Number min,
java.lang.Number max)
updateMinMax in class AbstractStatsValues<java.lang.Number>min - Value that the current minimum should be updated againstmax - Value that the current maximum should be updated againstprotected java.lang.Double toTypedValue(java.lang.String value)
toTypedValue in class AbstractStatsValues<java.lang.Number>value - String value to convertprotected void addTypeSpecificStats(NamedList<java.lang.Object> res)
addTypeSpecificStats in class AbstractStatsValues<java.lang.Number>res - NamedList to add the type specific statistics tooprivate double getStandardDeviation()