G01EFF returns the lower or upper tail probability of the gamma distribution, with parameters α and β, via the routine name.
The lower tail probability for the gamma distribution with parameters
α and
β,
PG≤g, is defined by:
The mean of the distribution is
αβ and its variance is
αβ2. The transformation
Z=Gβ is applied to yield the following incomplete gamma function in normalized form,
This is then evaluated using
S14BAF.
Hastings N A J and Peacock J B (1975)
Statistical Distributions Butterworth
If on entry
IFAIL=0 or
-1, explanatory error messages are output on the current error message unit (as defined by
X04AAF).
The result should have a relative accuracy of
machine precision. There are rare occasions when the relative accuracy attained is somewhat less than
machine precision but the error should not exceed more than
1 or
2 decimal places. Note also that there is a limit of
18 decimal places on the achievable accuracy, because constants in
S14BAF are given to this precision.
The time taken by G01EFF varies slightly with the input parameters
G,
A and
B.
This example reads in values from a number of gamma distributions and computes the associated lower tail probabilities.