Hello!
I need to randomly generate some time series data using EViews. They are as follows:
1) Xt = 0.2 - 0.6 Xt-1 + 0.3 Xt-2 + et
Yt = 0.2 + 0.6 Yt-1 - 0.3 Yt-2 + et
(sample size 400, the beginning values are to be set to zero, and et is N(0,1))
2) A trend-stationary time series with the specification:
Xt = 1.2 + 0.04t + et
(sample size 400)
I've been given the following example code for similar series:
workfile example1 u 1 201
series e = 0
series AR1=0
series AR2=0
series AR3=0
series AR4=0
rndseed 301
series e = nrnd
smpl 2 201
ar1 = 0.4*ar1(-1)+e
ar2 = -0.4*ar2(-1)+e
ar3 = 0.9*ar3(-1)+e
ar4 = -0.9*ar4(-1)+e
But, if I try, for example, this command: Xt = 0.2 - 0.6*Xt(-1) + 0.3*Xt(-2) I get all NAs (the second lag is the problem).
Can anyone please help me out?
Generating time series data in EViews 7
Moderators: EViews Gareth, EViews Moderator, EViews Jason, EViews Matt
-
EViews Gareth
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13584
- Joined: Tue Sep 16, 2008 5:38 pm
Re: Generating time series data in EViews 7
I don't see Xt anywhere in your example program.
-
startz
- Non-normality and collinearity are NOT problems!
- Posts: 3796
- Joined: Wed Sep 17, 2008 2:25 pm
Re: Generating time series data in EViews 7
Change
to
Code: Select all
smpl 2 201Code: Select all
smpl 3 201Re: Generating time series data in EViews 7
Thanks! That solved it!
Who is online
Users browsing this forum: No registered users and 1 guest
