[Table of Contents] [docx version]

SpreadsheetML Reference Material - Table of Contents

GAMMADIST

Syntax:

GAMMADIST ( x , alpha , beta , cumulative-flag )

Description: Computes the gamma distribution.

Mathematical Formula:

The equation for the gamma probability density function is:

The standard gamma probability density function is:

When alpha = 1, GAMMADIST returns the exponential distribution with:

For a positive integer n, when alpha = n/2, beta = 2, and cumulative = TRUE, GAMMADIST returns (1-CHIDIST(x)) with n degrees of freedom.

When alpha is a positive integer, GAMMADIST is also known as the Erlang distribution.

Arguments:

Name

Type

Description

x

number

The value at which the distribution is to be evaluated.

alpha

number

A parameter of the distribution.

beta

number

A parameter of the distribution. If beta = 1, GAMMADIST returns the standard gamma distribution.

cumulative-flag

logical

Determines the form of the function. If TRUE, GAMMADIST returns the cumulative distribution function; if FALSE, it returns the probability density function.

 

Return Type and Value: number – The gamma distribution.

However, if

x < 0, #NUM! is returned.

alpha ≤ 0 or beta ≤ 0, #NUM! is returned.

[Example:

GAMMADIST(10,9,2,FALSE) results in 0.03263902
GAMMADIST(10,9,2,TRUE) results in 0.068093631

end example]