|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectit.unimi.dsi.stat.SummaryStats
public class SummaryStats
A simple class digesting a stream of numbers and providing basic statistics about the stream.
You just have to create an instance, call add(double)
or add(double[])
to
add elements.
Constructor Summary | |
---|---|
SummaryStats()
|
Method Summary | |
---|---|
void |
add(double x)
Adds a value to the stream. |
void |
add(double[] a)
Deprecated. Use addAll(double[]) . |
void |
addAll(double[] a)
Adds values to the stream. |
void |
addAll(DoubleList l)
Adds values to the stream. |
double |
max()
Returns the maximum of the values added so far. |
double |
mean()
Returns the mean of the values added so far. |
double |
min()
Returns the minimum of the values added so far. |
double |
relativeStandardDeviation()
Returns the relative standard deviation of the values added so far. |
double |
sampleRelativeStandardDeviation()
Returns the sample relative standard deviation of the values added so far. |
double |
sampleStandardDeviation()
Returns the sample standard deviation of the values added so far. |
double |
sampleVariance()
Returns the sample variance of the values added so far. |
int |
size()
Deprecated. |
long |
size64()
Returns the number of values added so far. |
double |
standardDeviation()
Returns the standard deviation of the values added so far. |
double |
sum()
Returns the sum of the values added so far. |
double |
variance()
Returns the variance of the values added so far. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SummaryStats()
Method Detail |
---|
public void add(double x)
x
- the new value.@Deprecated public void add(double[] a)
addAll(double[])
.
a
- an array of new values.public void addAll(double[] a)
a
- an array of new values.public void addAll(DoubleList l)
l
- a list of new values.public double mean()
public double sum()
public double sampleVariance()
variance()
public double variance()
sampleVariance()
public double sampleStandardDeviation()
standardDeviation()
public double standardDeviation()
sampleStandardDeviation()
public double sampleRelativeStandardDeviation()
relativeStandardDeviation()
public double relativeStandardDeviation()
sampleRelativeStandardDeviation()
public double min()
public double max()
public long size64()
size64
in interface Size64
@Deprecated public int size()
size
in interface Size64
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |