ID EN
#Statistical

GAMMA.DIST

Excel Functions

Get the PDF or CDF of the gamma distribution

Syntax

EXCEL
=GAMMA.DIST(x, alpha, beta, cumulative)

Arguments

Parameter Description
x The value at which to evaluate the distribution.
alpha The shape parameter of the distribution.
beta The scale parameter of the distribution.
cumulative A logical value that determines the form of the function. If TRUE, returns the cumulative distribution function; if FALSE, returns the probability density function.

Return Value

Probability density or cumulative probability value

Details

The GAMMA.DIST function calculates values for the gamma distribution, which is a continuous probability distribution commonly used in statistical analysis. The gamma distribution is particularly useful for modeling positive continuous variables and has applications in reliability analysis, queuing theory, and meteorology. Suppose you work at a stall at the farmers' market. Customers appear one at a time, at random, but historical data tell you they arrive on average 10 per hour. How long will you wait until the 20th customer shows up? This scenario is a good example of when to use the gamma distribution, because it models the time until the k-th event occurs in a Poisson process (random arrivals at a constant average rate). To set up the problem as a gamma distribution: To calculate the ch

Examples

Example #1 - Farmers market stall customers

To calculate the chance of waiting ≤ x hours for the 20th customer, we calculate the probability like this:

EXCEL
=GAMMA.DIST(x, 20, 0.1, TRUE)
Example #1 - Farmers market stall customers

To calculate the chance of waiting > x hours for the 20th customer:

EXCEL
=1-GAMMA.DIST(x, 20, 0.1, TRUE)
Example #1 - Farmers market stall customers

For example, to find the probability that the 20th customer arrives in 2 hours or less, use:

EXCEL
=GAMMA.DIST(2, 20, 0.1, TRUE) // 53% chance of waiting ≤ 2 hours
Example #3 - Basic probability density calculations

In this example, we'll calculate the PDF for a gamma distribution with a shape (alpha) of 3 and a scale (beta) of 0.2. The formula is:

EXCEL
=GAMMA.DIST(x, 3, 0.2, FALSE)
Example #3 - Basic probability density calculations

The peak of the distribution (the mode) can be found with (alpha - 1) * beta, which is (3 - 1) * 0.2 = 0.4. We can calculate the PDF at this peak, and

EXCEL
=GAMMA.DIST(0.4, 3, 0.2, FALSE) // returns 1.353, the peak likelihood
=GAMMA.DIST(0.2, 3, 0.2, FALSE) // returns 0.981
=GAMMA.DIST(0.8, 3, 0.2, FALSE) // returns 0.903
Example #4 - Cumulative distribution calculations

Setting the cumulative argument to TRUE returns the cumulative distribution function (CDF), which gives the probability of a random variable being les

EXCEL
=GAMMA.DIST(0.7, 3, 0.2, TRUE) // returns 0.679

See Also

GAMMA.INV GAMMALN GAMMA EXPON.DIST