BETAINV
Updated 2023-11-02 16:00:07.517000
Syntax
SELECT [westclintech].[wct].[BETAINV](
<@Probability, float,>
,<@Alpha, float,>
,<@Beta, float,>
,<@A, float,>
,<@B, float,>)
Description
Use the scalar function BETAINV to calculate the quartiles of the beta cumulative distribution function.
Arguments
@A
The lower bound of the interval for @X. @A must be of a type float or of a type that intrinsically converts to float.
@Probability
The quartile to be evaluated. @Probability must be of a type float or of type that intrinsically converts to float.
@B
The upper bound of the interval for @X. @B must be of a type float or of a type that intrinsically converts to float.
@Beta
The second shape parameter for the distribution. @Beta must be of a type float or of a type that intrinsically converts to float.
@Alpha
The first shape parameter for the distribution. @Alpha must be of a type float or of a type that intrinsically converts to float.
Return Type
float
Remarks
@Alpha > 0.
@Beta > 0.
If @A is NULL then @A = 0.
If @B is NULL then @B = 1.
Examples
In this example we calculate the 95th percentile of a beta cumulative distribution function.
SELECT wct.BETAINV( 0.95, --@Probability
8, --@Alpha
10, --@Beta
1, --@A
3 --@B
) as BETAINV;
This produces the following result.
{"columns":[{"field":"BETAINV","headerClass":"ag-right-aligned-header","cellClass":"ag-right-aligned-cell"}],"rows":[{"BETAINV":"2.2719824535041"}]}
See Also
BETAI - Incomplete beta function
BETAPDF - Probability density function of the beta distribution