Sunteți pe pagina 1din 6

Simulare MODELE AUTOREGRESIVE i de MEDIE MOBIL Modelul AR(p) ACF Se amortizeaz tinznd la zero MA(q) Se anuleaz dup lagul

q Se amortizeaz tinznd la zero ARMA(p,q) Se amortizeaz tinznd la Se amortizeaz tinznd la zero


Simularea unui proces MA(1) : y t = t + t 1 y t = t + 0,9 * t 1 Am creat un fiier pentru 100 observaii Genr wn=nrnd Smpl 1 1 Genr maunu=wn Smpl 2 100 Genr maunu=wn+0,9*wn(-1) Smpl 1 100

PACF Se anuleaz dup lagul p

zero

Determinarea corelogramei seriei de date maunu: - Din meniul workfile selectm seria de date maunu. - Din meniul seriei maunu selectm View/Correlogram. Se deschide o fereastr n care selectm tipul seriei(level) i numrul de laguri (10) ce vor fi incluse n calcule.

Am artat c ACF pentru modelul de medie mobil y t = t + t 1 este:

i k = 0 pentru k > 1 . 1+ 2 S se determine ACF pentru modelul y t = t + 0,9 * t 1 i s se reprezinte grafic.

0 = 1 ; 1 =

0 = 1 ; 1 =

0,9 = 0,497 ; k = 0 pentru k > 1 1 + (0,9) 2

Modelul de medie mobil de ordinul doi, MA(2) y t = t + 1 t 1 + 2 t 2 , unde t ~ WN 0, 2 .)

Am determinat funcia de autocorelaie a lui y t .

0 = 1 , 1 =

1 + 1 2 2 , 2 = i k = 0 pentru k > 2 . 2 2 1 + 1 + 2 1 + 12 + 22

Simularea unui proces AR(1): yt = y t 1 + t yt = 0,8 * y t 1 + t Am creat un fiier pentru 100 observaii Genr wn=nrnd Smpl 1 1 Genr arunu=wn Smpl 2 100 Genr arunu= 0,8*arunu(-1)+wn Smpl 1 100

Pentru un modelul AR(1): yt = y t 1 + t am artat c: ACF este: k = k 1 = 2 k 1 = L = k , k .


PACF este: 11 = 1 = i kk = 0 pentru k > 1 .

S se determine ACF i PACF pentru modelul yt = 0,8 * y t 1 + t . ACF este: 0 = 1 ; 1 = = 0,8 ; 2 = 2 = (0,8) 2 = 0,64 ; 3 = 3 = (0,8) 3 = 0,512 ;...
PACF este: 11 = 1 = = 0,8 i kk = 0 pentru k > 1 .

Procesul este staionar deoarece < 1 .

Simularea unui proces AR(2): yt = 1 y t 1 + 2 y t 2 + t


yt = 1,1 * y t 1 0,6 * y t 2 + t Am creat un fiier pentru 100 observaii Genr wn=nrnd Smpl 1 1 Genr artwo=wn Smpl 2 2 Genr artwo=1,1*artwo(-1)+wn Smpl 3 100 Genr artwo=1,1*artwo(-1)-0,6*artwo(-2)+wn Smpl 1 100

Modelul AR(2) poate fi scris n mai multe moduri echivalente: yt = 1 y t 1 + 2 y t 2 + t yt 1 y t 1 2 y t 2 = t (1 1 L 2 L2 ) y t = t ( L) y t = t , unde ( L) = (1 1 L 2 L2 ) este polinomul autoregresiv al procesului AR(2).

Procesul este staionar iar polinomul ( L) = (1 1 L 2 L2 ) este inversabil dac rdcinile ecuaiei ( z ) = (1 1 z 2 z 2 ) = (1 1 z )(1 1 z ) = 0 se afl n afara cercului unitate, adic

z1 > 1 i z 2 > 1 sau echivalent, rdcinile ecuaiei P ( ) = 2 1 2 = 0 se afl n interiorul


cercului unitate, adic 1 < 1 i 2 < 1 . Pentru ca ultimele dou condiii s fie ndeplinite trebuie ca cei doi parametri ai modelului s satisfac urmtoarele condiii: 1 + 2 < 1 , 2 1 < 1 i | 2 |< 1 .

1, 2 =

1 12 + 4 2
2

Calcularea autocorelaiilor unui proces AR(2) nmulim ecuaia y t 1 y t 1 2 y t 2 = t prin y t k , dup care aplicm operatorul de medie i mprim prin variana 0 , a lui y t . Rezult urmtoarele relaii:

yt y t k 1 y t 1 y t k 2 y t 2 y t k = t yt k E ( y t y t k ) 1 E ( y t 1 y t k ) 2 E ( y t 2 y t k ) = E ( t y t k )

E ( y t yt k )

0 2 Pentru k = 0 obinem: E ( t y t ) = . Avem 0 1 1 2 2 = 2 0 (1 1 1 2 2 ) = 2 . Pentru k > 0 obinem: E ( t y t k ) = 0 . Deoarece E ( t y t k ) = E ( y t ) = 0 pentru toi t i k > 0 , obinem ecuaiile Yule-Walker: k 1 k 1 2 k 2 = 0 pentru k > 0 .
Determinarea funciei ACF:

E ( y t 1 y t k )

E ( yt 2 yt k )

E ( t yt k )

1 1 2 2 k = 2 2 1 1 2 0 = 0 2 = 1 1 + 2 2 = 1 + 2 1 2 k > 2 k = 1 k 1 + 2 k 2
k = 1 1 1 0 2 1 = 0 1 (1 2 ) = 1 1 =
Determinarea funciei PACF: Scriem ecuaiile Yule-Walker

1 = 1 + 12 2 = 11 + 2
Coeficienii de autocorelaie parial sunt: 11 = 1 ,

22 =

1
1

1 2 2 12 0 = 1 1 12
1

kk = 0 pentru k > 2 .
Ex1. yt = 0,6 y t 1 0,08 yt 2 + t Verificai dac este ndeplinit condiia de staionaritate. Avem 1 = 0,6 i 2 = 0,08
( L) = (1 1 L 2 L2 ) ( z ) = (1 1 z 2 z 2 ) = (1 1 z )(1 2 z ) = 0
P ( ) = 2 1 2 = 0 P ( ) = 2 0,6 + 0,08 = 0

1 = 0,4 i 2 = 0,2 , deci 1 < 1 i 2 < 1 .


Rezult z1 = 1 / 1 = 1 / 0,4 = 2,5 i z 2 = 1 / 2 = 1 / 0,2 = 5 , deci z1 > 1 i z 2 > 1 . Condiia de staionaritate este ndeplinit.

Ex2. yt = 1,1 y t 1 0,6 y t 2 + t a) Calculai ACF i reprezentai corelograma asociat. b) Calculai PACF i reprezentai corelograma corespunztoare. Avem 1 = 1,1 i 2 = 0,6 ACF: 1,1 1 = 1 = = 0,6875 1 2 1 (0,6) 2 = 0,15625 ; 3 = 0,24062 ; 4 = 0,35843 PACF: 11 = 1 = 0,6875 ,

22 =

2 12 = 0,6 1 12

kk = 0 pentru k > 2

S-ar putea să vă placă și