Dew Stats Master .NET
ARIMASimulate Routine
Summary
Simulate the ARIMA process.

Unit
StatTimeSerAnalysis

Declaration
Procedure ARIMASimulate(p, t: TVec; d: Integer; ResInit: TVec; n: integer; Result: TVec);
 Parameter  Description 
stores the AR coefficients. Length of the p vector defines AR(p) order. 
stores the MA coefficients. Length of the t vector defines MA(q) order. 
defines how many times time series is differentiated (d parameter in ARIMA). 
ResInit defines initial values for integration: r[-d+1],Dr[-d+2],...,D^(d-1)r[0]. The length of ResInit must be equal to d, otherwise an exception will be raised. 
defines number of points to simulate. 
Result returns ARIMA (p,d,q) time series. Size of Result vector is adjusted automatiacally. 

Description
Simulate the ARIMA (p,d,q) process.
Categories
ARMA and ARIMA routines
 See Also 
ARMASimulate 

Example 1

Simulate ARIMA(1,2,1) process with Phi=[1.0], Theta=[-0.25], d=2.
Uses MtxExpr, StatTimeSerAnalysis, Math387; procedure Example; var phi,theta,init,ts: Vector; begin phi.SetIt(false,[1.0]); theta.SetIt(false,[-0.25]); init.SetIt(false,[0,0]); ARIMASimulate(phi,theta,2,init,100,ts); // ts now stores 100 points from ARIMA(1,1,2) process. end;
#include "MtxVecCpp.h" #include "Math387.hpp" #include "StatTimeSerAnalysis.hpp" void __fastcall Example(); { Vector phi,theta,init,ts; phi->SetIt(false,OPENARRAY(TSample,(1.0))); theta->SetIt(false,OPENARRAY(TSample,(-0.25))); init->SetIt(false,OPENARRAY(TSample,(0,0))); ARIMASimulate(phi,theta,2,init,100,ts); // ts now stores 100 points from ARIMA(1,1,2) process. }
using Dew.Math; using Dew.Stats; using Dew.Stats.Units; namespace Dew.Examples { private void Example() { Vector phi = new Vector(0); Vector theta = new Vector(0); Vector init = new Vector(0); Vector ts = new Vector(0); phi.SetIt(false, new double[] {1.0}); theta.SetIt(false,new double[] {-0.25}); theta.SetIt(false,new double[] {0.0}); StatTimeSerAnalysis.ARIMASimulate(phi,theta,2,init,100,ts); // ts now stores 100 points from ARIMA(1,1,2) process. } }

Copyright 2008 Dew Research
http://www.dewresearch.com