edu.indiana.util.statistics
Class RunningRoundedMean

java.lang.Object
  extended by edu.indiana.util.statistics.RunningMean
      extended by edu.indiana.util.statistics.RunningRoundedMean
All Implemented Interfaces:
RunningAggregate, java.io.Serializable

public class RunningRoundedMean
extends RunningMean

This class is particularly useful for tracking an aggregate value for an ordinal variable.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class edu.indiana.util.statistics.RunningMean
max, min, numElements, sum
 
Constructor Summary
RunningRoundedMean()
          Creates a new instance of RunningRoundedMean
RunningRoundedMean(double sum, int numElements)
           
 
Method Summary
 double calcAggregateValue()
          Returns the rounded value of the aggregate calculated by RunningMean.
 
Methods inherited from class edu.indiana.util.statistics.RunningMean
add, equals, getMax, getMin, hashCode, remove, reset, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

RunningRoundedMean

public RunningRoundedMean()
Creates a new instance of RunningRoundedMean


RunningRoundedMean

public RunningRoundedMean(double sum,
                          int numElements)
Method Detail

calcAggregateValue

public double calcAggregateValue()
Returns the rounded value of the aggregate calculated by RunningMean.

Specified by:
calcAggregateValue in interface RunningAggregate
Overrides:
calcAggregateValue in class RunningMean