ISummaryStatistics.Fstat

Fore Syntax

Fstat: Double;

Fore.NET Syntax

Fstat: double;

Description

The Fstat property returns the Fisher statistics.

Comments

The statistic is used to check the hypothesis on the correlation between a dependent series and regressors.

Fore Example

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

Sub UserProc;
Var
    LinearR: SmLinearRegress;
    can, fr: Array[
9Of Double;
    res, i: Integer;
    Con: IIntercept;
    ss: ISummaryStatistics;
Begin
    LinearR := 
New SmLinearRegress.Create;
    
For i := 0 To 8 Do
        can[i] := 
1230 + i * 302;
        fr[i] := 
579.5 + i * 9.4;
    
End For;
    
// Set model parameters
    LinearR.Explained.Value := can;
    LinearR.Explanatories.Add.Value := fr;
    Con := LinearR.ModelCoefficients.Intercept;
    con.Mode := InterceptMode.ManualEstimate;
    con.Estimate := 
35.7;
    
// Calculate
    res := LinearR.Execute;
    ss := LinearR.SummaryStatistics;
    Debug.Write(
"Fisher statistic: ");
    Debug.WriteLine(ss.Fstat);
    Debug.Write(
"Probability for Fisher statistics: ");
    Debug.WriteLine(ss.ProbFstat);
    Debug.Write(
"Fisher statistic (uncentered): ");
    Debug.WriteLine(ss.Fstat_2);
    Debug.Write(
"Probability for Fisher statistics (uncentered): ");
    Debug.WriteLine(ss.ProbFstat_2);
End Sub UserProc;

After executing the example the console window displays summary statistics:

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
    LinearR: SmLinearRegress;
    can, fr: Array[9Of Double;
    res, i: Integer;
    Con: IIntercept;
    ss: ISummaryStatistics;
Begin
    LinearR := New SmLinearRegress.Create();
    For i := 0 To 8 Do
        can[i] := 1230 + i * 302;
        fr[i] := 579.5 + i * 9.4;
    End For;
    // Set model parameters
    LinearR.Explained.Value := can;
    LinearR.Explanatories.Add().Value := fr;
    Con := LinearR.ModelCoefficients.Intercept;
    con.Mode := InterceptMode.imManualEstimate;
    con.Estimate := 35.7;
    // Run calculation
    res := LinearR.Execute();
    ss := LinearR.SummaryStatistics;
    System.Diagnostics.Debug.Write("Fisher statistic: ");
    System.Diagnostics.Debug.WriteLine(ss.Fstat);
    System.Diagnostics.Debug.Write("Probability for Fisher statistics: ");
    System.Diagnostics.Debug.WriteLine(ss.ProbFstat);
    System.Diagnostics.Debug.Write("Fisher statistic (uncentered): ");
    System.Diagnostics.Debug.WriteLine(ss.Fstat_2);
    System.Diagnostics.Debug.Write("Probability for Fisher statistics (uncentered): ");
    System.Diagnostics.Debug.WriteLine(ss.ProbFstat_2);
End Sub;

See also:

ISummaryStatistics | Fisher Statistic