|
CFEngine API | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.recommender.server.Stats
Calculates Mean or Standard Deviation for a set of numbers. To use this class, add each number of the set separately. Then call calcMean or calcSD.
Constructor Summary | |
Stats()
Default constructor. |
Method Summary | |
void |
addNum(float val)
Adds the value to the existing set of numbers. |
float |
calcMean()
Returns the mean for the numbers in the set. |
float |
calcSD()
Returns the standard deviation for the numbers in the set. |
int |
size()
Returns the number of numbers in the set. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public Stats()
Method Detail |
public void addNum(float val)
val
- public float calcSD()
public float calcMean()
public int size()
|
CFEngine API | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |