represents a geometric distribution with probability parameter p.
- The probability for value in a geometric distribution is for non-negative integers, and is zero otherwise. »
- GeometricDistribution[p] is the distribution of the number of failures in a sequence of trials with success probability p before a success occurs.
- GeometricDistribution allows p to be a dimensionless quantity. »
- GeometricDistribution can be used with such functions as Mean, CDF, and RandomVariate. »
Background & Context
- GeometricDistribution[p] represents a discrete statistical distribution defined at integer values and parametrized by a non-negative real number . The geometric distribution has a discrete probability density function (PDF) that is monotonically decreasing, with the parameter p determining the height and steepness of the PDF. The geometric distribution is sometimes referred to as the Furry distribution.
- The geometric distribution is sometimes said to be the discrete analog of the exponential distribution (ExponentialDistribution). It can be defined as the distribution that models the number of Bernoulli trials (i.e. number of trials of a variate having a BernoulliDistribution) needed to obtain a single success. The geometric distribution has been used to model a number of different phenomena across many fields, including the behavior of competing plant populations, dynamics of ticket control, particulars of congenital malformations, and estimation of animal abundance. Moreover, the geometric distribution has been used widely in reliability theory and is a staple in Markov chain models for meteorology, queueing theory, and applied stochastics.
- RandomVariate can be used to give one or more machine- or arbitrary-precision (the latter via the WorkingPrecision option) pseudorandom variates from a geometric distribution. Distributed[x,GeometricDistribution[p]], written more concisely as xGeometricDistribution[p], can be used to assert that a random variable x is distributed according to a geometric distribution. Such an assertion can then be used in functions such as Probability, NProbability, Expectation, and NExpectation.
- The probability density and cumulative distribution functions may be given using PDF[GeometricDistribution[p],x] and CDF[GeometricDistribution[p],x]. The mean, median, variance, raw moments, and central moments may be computed using Mean, Median, Variance, Moment, and CentralMoment, respectively. These quantities can be visualized using DiscretePlot.
- DistributionFitTest can be used to test if a given dataset is consistent with a geometric distribution, EstimatedDistribution to estimate a geometric parametric distribution from given data, and FindDistributionParameters to fit data to a geometric distribution. ProbabilityPlot can be used to generate a plot of the CDF of given data against the CDF of a symbolic geometric distribution and QuantilePlot to generate a plot of the quantiles of given data against the quantiles of a symbolic geometric distribution.
- TransformedDistribution can be used to represent a transformed geometric distribution, CensoredDistribution to represent the distribution of values censored between upper and lower values, and TruncatedDistribution to represent the distribution of values truncated between upper and lower values. CopulaDistribution can be used to build higher-dimensional distributions that contain a geometric distribution, and ProductDistribution can be used to compute a joint distribution with independent component distributions involving geometric distributions.
- GeometricDistribution is related to a number of other statistical distributions. For example, GeometricDistribution is a special case of the more general NegativeBinomialDistribution, in the sense that NegativeBinomialDistribution[1,p] has precisely the same PDF as GeometricDistribution[p] and that the sum of is distributed according to NegativeBinomialDistribution[n,p], provided that XiGeometricDistribution[p] for all . GeometricDistribution is also a transformation of PascalDistribution and can be viewed as a parameter mixture of PoissonDistribution with either GammaDistribution or ExponentialDistribution, in the sense that both ParameterMixtureDistribution[PoissonDistribution[μ],μGammaDistribution[1,(1-p)/p]] and ParameterMixtureDistribution[PoissonDistribution[μ],μ ExponentialDistribution[p/(1-p)]] are the same as GeometricDistribution[p]. GeometricDistribution is also related to WaringYuleDistribution, BinomialDistribution, PascalDistribution, and HypergeometricDistribution.
Examplesopen allclose all
Basic Examples (3)
A cereal box contains one out of a set of different plastic animals. The animals are equally likely to occur, independently of what animals are in other boxes. Simulate the animal collection process, assuming there are 10 animals for 25 boxes:
After unique animals have been collected, the number of boxes needed to find a new unique animal among the remaining follows a geometric distribution with parameter . Find the expected number of boxes needed to get a new unique animal:
When a computer accesses memory, the desired data is in the cache with probability p. A cache miss occurs if the desired data is not in the cache. Find the probability of a cache miss on the memory access:
A data stream containing data packets is repeatedly sent without order information. Find the distribution of the number of tries until the data stream arrives with all the packets in the right order for the first time:
A player bets amount in a casino with no betting limit in a game with chance of winning . If he loses he doubles the bet, and if he wins he quits, hence the number of games played follows a geometric distribution, with expected number of games played represented as follows:
In an optical communication system, transmitted light generates current at the receiver. The number of electrons follows the parametric mixture of Poisson distribution and other distributions, depending on the type of light. If the source uses coherent laser light of intensity , then the electron count distribution is Poisson:
Which is PoissonDistribution:
If the source uses thermal illumination, then the Poisson parameter follows ExponentialDistribution with parameter , and the electron count distribution is:
Properties & Relations (8)
NegativeBinomialDistribution simplifies to geometric distribution:
Sum of independent geometric variables has NegativeBinomialDistribution:
Geometric distribution is a transformation of PascalDistribution:
It is the same as the mixture with an ExponentialDistribution:
Possible Issues (2)
GeometricDistribution is not defined when p is not between zero and one: