JarqueBeraStat(Sample: Array): Double;
The JarqueBeraStat method returns the Jarque-Bera statistics.
The Jarque-Bera test is used to test the hypothesis that the residuals of the considered series have normal distribution.
Test statistic has χ2 distribution with two degrees of freedom. Null hypothesis of normal distribution of series residuals is rejected at selected significance, if Jarque-Bera statistic is greater than critical value of χ2 statistics (critical value of χ2 for significance level 0.01 is 9.2103, for significance level 0.05 it is 5.9916).
To execute the example, add a link to the Stat system assembly.
Sub UserProc;
Var
st: Statistics;
JB: Double;
y: Array Of Double;
Begin
y := New Double[10];
y[00] := 6209;
y[01] := 6385;
y[02] := 6752;
y[03] := 6837;
y[04] := 6495;
y[05] := 6907;
y[06] := 7349;
y[07] := 7213;
y[08] := 7061;
y[09] := 7180;
st := New Statistics.Create;
JB := st.JarqueBeraStat(y);
Debug.WriteLine("JarqueBera: " + JB.ToString);
End Sub UserProc;
Executing the example shows the Jarque-Bera statistics results in the console window:
Unit execution started
JarqueBera: 0.690670107648513
Unit execution finished
See also: