IArimaSpecification.AutoRegressionOrder

Syntax

AutoRegressionOrder: Integer;

Description

The AutoRegressionOrder property determines autoregression order.

Comments

Default property value is 1.

Example

Sub Main;

Var

ARIMA: SmArima;

can: Array Of Double;

res, i: Integer;

d0: Double;

Begin

ARIMA := New SmArima.Create;

can := New Double[5];

can[00] := 6209;

can[01] := 6385;

can[02] := 6752;

can[03] := 6837;

can[04] := 6495;

ARIMA.Serie.Value := can;

ARIMA.Forecast.LastPoint := 12;

ARIMA.ArimaSpecification.AutoRegressionOrder := 0;

ARIMA.ArimaSpecification.MovingAverageOrder := 1;

ARIMA.ModelCoefficients.Intercept.Mode := InterceptMode.AutoEstimate;

res := ARIMA.Execute;

Debug.WriteLine(res); // display execution status

Debug.WriteLine("=== Modeling series === "); // display data series in the console window

For i := 0 To ARIMA.ModelPeriod.LastPoint - 1 Do

d0 := ARIMA.Fitted[i];

Debug.WriteLine(i.ToString + ", " + d0.ToString);

End For;

End Sub Main;

After executing the example the console window displays the following result:

Module execution started

0

=== Modeling series ===

0, 6178.6666664911972

1, 6148.6666664872982

2, 6636.6666640814246

3, 6942.6666679027476

4, 6495

Module execution finished

See also:

IArimaSpecification