Package edu.berkeley.cs.jqf.fuzz.util
Class MovingAverage
- java.lang.Object
-
- edu.berkeley.cs.jqf.fuzz.util.MovingAverage
-
public class MovingAverage extends Object
MovingAverage - A data structure for collecting a moving average.- Author:
- Raffi Sanna
-
-
Constructor Summary
Constructors Constructor Description MovingAverage(int cap)
Constructs a moving average of the most recentcap
arguments
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
add(int a)
Adds a number to the set of numbers used to find the moving average.double
get()
Gets the moving average itself, or0
if nothing has been added.
-