@ExperimentalApi @Immutable public abstract class Distribution extends Object
Distribution contains summary statistics for a population of values. It optionally
contains a histogram representing the distribution of those values across a set of buckets.| Modifier and Type | Class and Description |
|---|---|
static class |
Distribution.Bucket
The histogram bucket of the population values.
|
static class |
Distribution.BucketOptions
The bucket options used to create a histogram for the distribution.
|
| Modifier and Type | Method and Description |
|---|---|
static Distribution |
create(long count,
double sum,
double sumOfSquaredDeviations,
Distribution.BucketOptions bucketOptions,
List<Distribution.Bucket> buckets)
Creates a
Distribution. |
abstract Distribution.BucketOptions |
getBucketOptions()
Returns bucket options used to create a histogram for the distribution.
|
abstract List<Distribution.Bucket> |
getBuckets()
Returns the aggregated histogram
Distribution.Buckets. |
abstract long |
getCount()
Returns the aggregated count.
|
abstract double |
getSum()
Returns the aggregated sum.
|
abstract double |
getSumOfSquaredDeviations()
Returns the aggregated sum of squared deviations.
|
public static Distribution create(long count, double sum, double sumOfSquaredDeviations, Distribution.BucketOptions bucketOptions, List<Distribution.Bucket> buckets)
Distribution.count - the count of the population values.sum - the sum of the population values.sumOfSquaredDeviations - the sum of squared deviations of the population values.bucketOptions - the bucket options used to create a histogram for the distribution.buckets - Distribution.Buckets of a histogram.Distribution.public abstract long getCount()
public abstract double getSum()
public abstract double getSumOfSquaredDeviations()
The sum of squared deviations from the mean of the values in the population. For values x_i this is:
Sum[i=1..n]((x_i - mean)^2)
If count is zero then this field must be zero.
@Nullable public abstract Distribution.BucketOptions getBucketOptions()
BucketOptions associated with the Distribution, or null if
there isn't one.public abstract List<Distribution.Bucket> getBuckets()
Distribution.Buckets.