## 8 Probability Distributions## 8.1 OverviewStandard distributions are now available in the Commons Statistics component. Commons Math provides - an EnumeratedDistribution class that represents discrete distributions of a finite, enumerated set of values.
- a MultivariateNormalDistribution interface that represents multivariate Gaussian distributions.
Inverse distribution functions can be computed using the
```
``` where `X` is distributed as `f` .For discrete `f` , the definition is the same, with `Z` (the integers)
in place of `R` . Note that in the discrete case, the ≥ in the definition
can make a difference when `p` is an attained value of the distribution.
## 8.2 Generating data like an input file
Using the double[] input = load("data.txt"); // Get some data. int binCount = 500; EmpiricalDistribution empDist = EmpiricalDistribution.from(binCount, input); ContinuousDistribution.Sampler sampler = empDist.createSampler(RandomSource.MT.create()); double value = sampler.nextDouble(); |