# Discrete Distributions

The functions described here are among the most commonly used discrete univariate statistical distributions. You can compute their densities, means, variances, and other related properties. The distributions themselves are represented in the symbolic form name[param_{1},param_{2},…]. Functions such as Mean, which give properties of statistical distributions, take the symbolic representation of the distribution as an argument. "Continuous Distributions" describes many continuous statistical distributions.

BernoulliDistribution[p] | Bernoulli distribution with mean p |

BetaBinomialDistribution[α,β,n] | binomial distribution where the success probability is a BetaDistribution[α,β] random variable |

BetaNegativeBinomialDistribution[α,β,n] | |

negative binomial distribution where the success probability is a BetaDistribution[α,β] random variable | |

BinomialDistribution[n,p] | binomial distribution for the number of successes that occur in n trials, where the probability of success in a trial is p |

DiscreteUniformDistribution[{i_{min},i_{max}}] | |

discrete uniform distribution over the integers from i_{min} to i_{max} | |

GeometricDistribution[p] | geometric distribution for the number of trials before the first success, where the probability of success in a trial is p |

HypergeometricDistribution[n,n_{succ},n_{tot}] | |

hypergeometric distribution for the number of successes out of a sample of size n, from a population of size n_{tot} containing n_{succ} successes | |

LogSeriesDistribution[θ] | logarithmic series distribution with parameter θ |

NegativeBinomialDistribution[n,p] | negative binomial distribution with parameters n and p |

PoissonDistribution[μ] | Poisson distribution with mean μ |

ZipfDistribution[ρ] | Zipf distribution with parameter ρ |

Discrete statistical distributions.

Most of the common discrete statistical distributions can be understood by considering a sequence of trials, each with two possible outcomes, for example, success and failure.

The *Bernoulli distribution* BernoulliDistribution[p] is the probability distribution for a single trial in which success, corresponding to value 1, occurs with probability Null, and failure, corresponding to value 0, occurs with probability Null.

The *binomial distribution* BinomialDistribution[n,p] is the distribution of the number of successes that occur in Null independent trials, where the probability of success in each trial is Null.

The *negative binomial distribution* NegativeBinomialDistribution[n,p] for positive integer Null is the distribution of the number of failures that occur in a sequence of trials before Null successes have occurred, where the probability of success in each trial is Null. The distribution is defined for any positive Null, though the interpretation of Null as the number of successes and Null as the success probability no longer holds if Null is not an integer.

The *beta binomial distribution *BetaBinomialDistribution[α,β,n] is a mixture of binomial and beta distributions. A BetaBinomialDistribution[α,β,n] random variable follows a BinomialDistribution[n,p] distribution, where the success probability Null is itself a random variable following the beta distribution BetaDistribution[α,β]. The *beta negative binomial distribution *BetaNegativeBinomialDistribution[α,β,n] is a similar mixture of the beta and negative binomial distributions.

The *geometric distribution* GeometricDistribution[p] is the distribution of the total number of trials before the first success occurs, where the probability of success in each trial is Null.

The *hypergeometric distribution* HypergeometricDistribution[n,n_{succ},n_{tot}] is used in place of the binomial distribution for experiments in which the Null trials correspond to sampling without replacement from a population of size n_{tot} with n_{succ} potential successes.

The *discrete uniform distribution* DiscreteUniformDistribution[{i_{min},i_{max}}] represents an experiment with multiple equally probable outcomes represented by integers i_{min} through i_{max}.

The *Poisson distribution* PoissonDistribution[μ] describes the number of events that occur in a given time period where Null is the average number of events per period.

The terms in the series expansion of about are proportional to the probabilities of a discrete random variable following the *logarithmic series distribution* LogSeriesDistribution[θ]. The distribution of the number of items of a product purchased by a buyer in a specified interval is sometimes modeled by this distribution.

The *Zipf distribution* ZipfDistribution[ρ], sometimes referred to as the zeta distribution, was first used in linguistics and its use has been extended to model rare events.

PDF[dist,x] | probability mass function at x |

CDF[dist,x] | cumulative distribution function at x |

InverseCDF[dist,q] | the largest integer x such that CDF[dist,x] is at most q |

Quantile[dist,q] | q quantile |

Mean[dist] | mean |

Variance[dist] | variance |

StandardDeviation[dist] | standard deviation |

Skewness[dist] | coefficient of skewness |

Kurtosis[dist] | coefficient of kurtosis |

CharacteristicFunction[dist,t] | characteristic function |

Expectation[f[x],xdist] | expectation of f[x] for x distributed according to dist |

Median[dist] | median |

Quartiles[dist] | list of the , , quantiles for dist |

InterquartileRange[dist] | difference between the first and third quartiles |

QuartileDeviation[dist] | half the interquartile range |

QuartileSkewness[dist] | quartile‐based skewness measure |

RandomVariate[dist] | pseudorandom number with specified distribution |

RandomVariate[dist,dims] | pseudorandom array with dimensionality dims, and elements from the specified distribution |

Some functions of statistical distributions.

Distributions are represented in symbolic form. PDF[dist,x] evaluates the mass function at x if x is a numerical value, and otherwise leaves the function in symbolic form whenever possible. Similarly, CDF[dist,x] gives the cumulative distribution and Mean[dist] gives the mean of the specified distribution. The table above gives a sampling of some of the more common functions available for distributions. For a more complete description of these functions, see the description of their continuous analogues in "Continuous Distributions".