NAG Library Routine Document
G01FDF returns the deviate associated with the given lower tail probability of the or variance-ratio distribution with real degrees of freedom, via the routine name.
|REAL (KIND=nag_wp) G01FDF
||P, DF1, DF2
, associated with the lower tail probability,
, of the
-distribution with degrees of freedom
is defined as the solution to
The value of
is computed by means of a transformation to a beta distribution,
and using a call to G01FEF
For very large values of both
, greater than
, a normal approximation is used. If only one of
is greater than
approximation is used; see Abramowitz and Stegun (1972)
Abramowitz M and Stegun I A (1972) Handbook of Mathematical Functions (3rd Edition) Dover Publications
Hastings N A J and Peacock J B (1975) Statistical Distributions Butterworth
- 1: P – REAL (KIND=nag_wp)Input
On entry: , the lower tail probability from the required -distribution.
- 2: DF1 – REAL (KIND=nag_wp)Input
On entry: the degrees of freedom of the numerator variance, .
- 3: DF2 – REAL (KIND=nag_wp)Input
On entry: the degrees of freedom of the denominator variance, .
- 4: IFAIL – INTEGERInput/Output
must be set to
. If you are unfamiliar with this parameter you should refer to Section 3.3
in the Essential Introduction for details.
For environments where it might be inappropriate to halt program execution when an error is detected, the value
is recommended. If the output of error messages is undesirable, then the value
is recommended. Otherwise, because for this routine the values of the output parameters may be useful even if
on exit, the recommended value is
. When the value is used it is essential to test the value of IFAIL on exit.
unless the routine detects an error or a warning has been flagged (see Section 6
6 Error Indicators and Warnings
If on entry
, explanatory error messages are output on the current error message unit (as defined by X04AAF
Note: G01FDF may return useful information for one or more of the following detected errors or warnings.
Errors or warnings detected by the routine:
If on exit , or , then G01FDF returns .
The solution has not converged. The result should still be a reasonable approximation to the solution. Alternatively, G01FEF
can be used with a suitable setting of the parameter TOL
The value of P
is too close to
for the value of
to be computed. This will only occur when the large sample approximations are used.
The result should be accurate to five significant digits.
For higher accuracy G01FEF
can be used along with the transformations given in Section 3
This example reads the lower tail probabilities for several -distributions, and calculates and prints the corresponding deviates until the end of data is reached.
9.1 Program Text
Program Text (g01fdfe.f90)
9.2 Program Data
Program Data (g01fdfe.d)
9.3 Program Results
Program Results (g01fdfe.r)