g01fb returns the deviate associated with the given tail probability of Student's -distribution with real degrees of freedom.
Syntax
C# |
---|
public static double g01fb( string tail, double p, double df, out int ifail ) |
Visual Basic |
---|
Public Shared Function g01fb ( _ tail As String, _ p As Double, _ df As Double, _ <OutAttribute> ByRef ifail As Integer _ ) As Double |
Visual C++ |
---|
public: static double g01fb( String^ tail, double p, double df, [OutAttribute] int% ifail ) |
F# |
---|
static member g01fb : tail : string * p : float * df : float * ifail : int byref -> float |
Parameters
- tail
- Type: System..::..StringOn entry: indicates which tail the supplied probability represents.
- The upper tail probability, i.e., .
- The lower tail probability, i.e., .
- The two tail (significance level) probability, i.e., .
- The two tail (confidence interval) probability, i.e., .
Constraint: , , or .
- p
- Type: System..::..DoubleOn entry: , the probability from the required Student's -distribution as defined by tail.Constraint: .
- df
- Type: System..::..DoubleOn entry: , the degrees of freedom of the Student's -distribution.Constraint: .
- ifail
- Type: System..::..Int32%On exit: unless the method detects an error or a warning has been flagged (see [Error Indicators and Warnings]).
Return Value
g01fb returns the deviate associated with the given tail probability of Student's -distribution with real degrees of freedom.
Description
The deviate, associated with the lower tail probability, , of the Student's -distribution with degrees of freedom is defined as the solution to
For the integral equation is easily solved for .
For other values of a transformation to the beta distribution is used and the result obtained from g01fe.
For an inverse asymptotic expansion of Cornish–Fisher type is used. The algorithm is described by Hill (1970).
References
Hastings N A J and Peacock J B (1975) Statistical Distributions Butterworth
Hill G W (1970) Student's -distribution Comm. ACM 13(10) 617–619
Error Indicators and Warnings
Note: g01fb may return useful information for one or more of the following detected errors or warnings.
Errors or warnings detected by the method:
If , or on exit, then g01fb returns zero.
On entry, , , or .
On entry, , or .
On entry, .
- Convergence in the calculation of the inverse beta value was not achieved. However, the result should be a reasonable approximation to the correct value.
Accuracy
The results should be accurate to five significant digits, for most parameter values. The error behaviour for various parameter values is discussed in Hill (1970).
Parallelism and Performance
None.
Further Comments
The value may be calculated by using the transformation described in [Description] and using g01fe. This method allows you to set the required accuracy.
Example
This example reads the probability, the tail that probability represents and the degrees of freedom for a number of Student's -distributions and computes the corresponding deviates.
Example program (C#): g01fbe.cs