java.lang.Object
com.aoapps.lang.math.Statistics
Some basic statistics algorithms.
- Author:
- AO Industries, Inc.
-
Method Summary
Modifier and TypeMethodDescriptionstatic double
mean
(Collection<? extends Number> samples) Computes the average of a set of samples.static double
standardDeviation
(double mean, Collection<? extends Number> samples) Computes the standard deviation of a set of samples.
-
Method Details
-
mean
Computes the average of a set of samples.null
values will be ignored, not contributing to the average in any way.- Parameters:
samples
- must have at least one sample- Returns:
- Double.NaN if there are no samples
-
standardDeviation
Computes the standard deviation of a set of samples.null
values will be ignored, not contributing to the deviation in any way. This does not use Bessel's correction.
-