IStatistics.CritBinom

Fore Syntax

CritBinom(Trials: Integer; Probability: Double; Alpha: Double): Integer;

Fore.NET Syntax

CritBinom(Trials: integer; Probability: double; Alpha: double): integer;

Parameters

Trials. The number of Bernoulli trials.

Probability. Success probability for each trial.

Alpha. Criterion value.

Description

The CritBinom method returns the least value for which integral binomial distribution is greater or equal to the specified criterion. This function is used in quality control applications.

Comments

Value of the Trials parameter must be greater of equal to zero.

Tolerance range of the Probability parameter: [0; 1].

Tolerance range of the Alpha parameter: [0; 1].

Fore Example

To execute the example, add a link to the Stat system assembly.

Sub UserProc;
Var
    st: Statistics;
    d0: Double;
Begin
    st := 
New Statistics.Create;
    d0 := st.CritBinom(
60.5,0.75);
    
If st.Status <> 0 Then
        Debug.WriteLine(st.Errors);
    
Else
        Debug.WriteLine(
"Least value: " + d0.ToString);
    
End If;
End Sub UserProc;

After executing the example the console window displays the least value.

Fore.NET Example

The requirements and result of the Fore.NET example execution match with those in the Fore example.

Imports Prognoz.Platform.Interop.Stat;

Public Shared Sub Main(Params: StartParams);
Var
    st: Statistics;
    d0: Double;
Begin
    st := New Statistics.Create();
    d0 := st.CritBinom(60.5,0.75);
    If st.Status <> 0 Then
        System.Diagnostics.Debug.WriteLine(st.Errors);
    Else
        System.Diagnostics.Debug.WriteLine("Least value: " + d0.ToString());
    End If;
End Sub;

See also:

IStatistics