Model / stats · All operations
Use a probability distribution
Distribution functions, density estimation.
Status
- In arcform
Not built yet
arcform does not do this yet. Its place on the roadmap
- Shape of the result
- a table describing the input rather than holding its rows
- Level
- needs a DuckDB extension
Variants
- Estimate density from data
Fit a density to a sample, by kernels or a density tree, and read it at query points.
Evaluate a probability distribution
Compute densities, probabilities or samples from a named probability distribution.
What other tools call it
Meridian's classification; an independent blind rating agreed on 86.2% of 312 rows (exact class, version 2).
mlpack (3)
Distributionsread 2026-09-27Probability distribution classes
mlpack_detread 2026-09-27Density estimation trees: train one, or predict density at query points
mlpack_kderead 2026-09-27Kernel density estimation at query points, with dual-tree algorithms
Background
A probability distribution describes how probabilities are assigned to the possible results of a random phenomenon.[1] A random variable assigns a value to each outcome of a probabilistic experiment and induces a probability distribution on the values it can take.[1] Probability distributions are often described by cumulative distribution functions, probability mass functions or probability density functions.[1]
When to use it
The quantile function of a probability distribution is the inverse of its cumulative distribution function.[2] A statistical application may need key percentage points of a distribution, such as its 2.5% and 97.5% levels, to assess the statistical significance of an observation whose distribution is known.[2] The quantile of the standard normal distribution at 0.975 is 1.96.[3] Quantile functions are used in both statistical applications and Monte Carlo methods.[2]
Unlike a probability, a probability density function can take on values greater than one.[4] The probability for a continuous random variable to take on any particular value is zero.[4] The probability of a continuous random variable falling within a range of values is given by the integral of its probability density function over that range.[4] Treat a density value as a relative likelihood to compare with other density values, and turn to the cumulative distribution function when the question is the chance of a range. (Meridian's view)
The method
The cumulative distribution function of a real-valued random variable X, evaluated at x, is the probability that X will take a value less than or equal to x.[5] For a continuous distribution, the cumulative distribution function at a value is the area under the probability density function up to that value.[1] Probability mass functions are used for discrete distributions, while probability density functions are used for many continuous distributions.[1] The probability density function of a continuous random variable can be determined from its cumulative distribution function by differentiating.[5]
Inverse transform sampling, also known as inversion sampling, is a basic method for generating sample numbers at random from any probability distribution given its cumulative distribution function.[6] Inverse transform sampling takes uniform samples of a number between 0 and 1, interpreted as a probability.[6] Computationally, inverse transform sampling involves computing the quantile function of the distribution.[6] For the normal distribution, the lack of an analytical expression for the quantile function means that other methods, such as the Box–Muller transform, may be preferred computationally.[6] Inversion sampling is now the default method for sampling from a normal distribution in the statistical package R.[6]
In mlpack, the GaussianDistribution, GammaDistribution and LaplaceDistribution classes each compute probabilities of points, sample from the distribution and fit the distribution to observations.[7]
Compared with the alternatives
Parametric statistics assumes that the distribution the observed data was drawn from can be described by a finite set of unknown parameters.[8] Nonparametric statistics does not assume explicit finite-parametric mathematical forms for distributions when modelling data.[8] Most well-known statistical methods are parametric.[8] Nonparametric methods make fewer assumptions, so their applicability is much more general than that of the corresponding parametric methods.[9] When the form of a distribution is in doubt, an estimate from the sample is a gentler place to start than a named distribution chosen on faith. (Meridian's view)
Sources
- [1]Probability distributionsecondary source
- [2]Quantile functionsecondary source
- [3]Normal distributionsecondary source
- [4]Probability density functionsecondary source
- [5]Cumulative distribution functionsecondary source
- [6]Inverse transform samplingsecondary source
- [7]mlpack documentationdocumentation
- [8]Parametric statisticssecondary source
- [9]Nonparametric statisticssecondary source