# naginterfaces.library.stat.prob_​f_​noncentral¶

naginterfaces.library.stat.prob_f_noncentral(f, df1, df2, rlamda, tol=0.0, maxit=500)[source]

prob_f_noncentral returns the probability associated with the lower tail of the noncentral or variance-ratio distribution.

For full information please refer to the NAG Library document for g01gd

https://www.nag.com/numeric/nl/nagdoc_28.4/flhtml/g01/g01gdf.html

Parameters
ffloat

, the deviate from the noncentral -distribution.

df1float

The degrees of freedom of the numerator variance, .

df2float

The degrees of freedom of the denominator variance, .

rlamdafloat

, the noncentrality parameter.

tolfloat, optional

The relative accuracy required by you in the results. If prob_f_noncentral is entered with greater than or equal to or less than (see machine.precision), the value of is used instead.

maxitint, optional

The maximum number of iterations to be used.

Returns
pfloat

The probability associated with the lower tail of the noncentral or variance-ratio distribution.

Raises
NagValueError
(errno )

On entry, .

Constraint: .

(errno )

On entry, .

Constraint: , where is the safe range parameter as defined by machine.real_safe.

(errno )

On entry, .

Constraint: .

(errno )

On entry, .

Constraint: .

(errno )

On entry, .

Constraint: .

(errno )

On entry, .

Constraint: .

(errno )

The solution has failed to converge in iterations. Consider increasing or .

(errno )

The required probability cannot be computed accurately. This may happen if the result would be very close to zero or one. Alternatively the values of and may be too large. In the latter case you could try using a normal approximation, see Abramowitz and Stegun (1972).

Warns
NagAlgorithmicWarning
(errno )

The required accuracy was not achieved when calculating the initial value of the central or probability. You should try a larger value of . If the approximation is being used then prob_f_noncentral returns zero otherwise the value returned should be an approximation to the correct value.

Notes

The lower tail probability of the noncentral -distribution with and degrees of freedom and noncentrality parameter , , is defined by

where

and is the beta function.

The probability is computed by means of a transformation to a noncentral beta distribution:

where and is the lower tail probability integral of the noncentral beta distribution with parameters , , and .

If is very large, greater than , then a approximation is used.

References

Abramowitz, M and Stegun, I A, 1972, Handbook of Mathematical Functions, (3rd Edition), Dover Publications