Hi! I have a state-space model estimated from 1996Q1 to 2010Q4. I'm using the following program to run the estimations:
smpl 1996:1 2010:4
sym (4) cov_c
cov_c = @identity(4)
sspace kmc1_r
kmc1_r.append @vprior cov_c
'Ecuaciones de señal
kmc1_r.append @signal dl1pib_sa = sv4 + sv1 - sv2
kmc1_r.append @signal dl1ipc_sa = sv3 + [var = 1]
kmc1_r.append @signal dl1itcrm = sv6 - sv7 + sv5
kmc1_r.append @signal tea_rp = sv8 + sv9
kmc1_r.append @signal d1bp = sv11 - sv13 + sv10 + [var = 2]
'Ecuaciones de estado:
kmc1_r.append @state sv1=c(1) * sv2 + c(2) * sv15 + c(3) * sv7 + c(4) * sv14 +[var = exp(c(1))]
kmc1_r.append @state sv2 =sv1(-1)
kmc1_r.append @state sv3 = c(5) * sv3(-1) + c(6) * dl1ipcm + c(7) * sv2 + c(8) * dl1ipc_sa(+1) + [var = exp(c(5))]
kmc1_r.append @state sv4 = c(9) + c(10) * sv4(-1) + [var = exp(c(10))]
kmc1_r.append @state sv5 = c(11) + c(12) * sv10 + c(13) * dl1itcer + c(14) * sv4 + [var = exp(c(3))]
kmc1_r.append @state sv6 = c(15) * sv7 + [var = exp(c(15))]
kmc1_r.append @state sv7 = sv6(-1)
kmc1_r.append @state sv8 = c(16) + c(17) * libor + sv5 + [var = 3]
kmc1_r.append @state sv9 = c(18) * sv9(-1) + [var = exp(c(18))]
kmc1_r.append @state sv10 = c(19) * sv10(-1) + [var = exp(c(19))]
kmc1_r.append @state sv11 = c(20) * sv1+ [var = exp(c(1))]
kmc1_r.append @state sv12 = sv10(-1)
kmc1_r.append @state sv13 = sv11(-1)
kmc1_r.append @state sv14 = c(21) * sv14(-1) + [var = exp(c(4))]
kmc1_r.append @state sv15 = sv9(-1)
kmc1_r.ml
kmc1_r.makestates(t=smooth) k1*
stop
I can't find the error but an error message appears every time I try to run the model. Can anyone help me please?
You can find attached the workfile.
Thanks!.
A.
State space specification
Moderators: EViews Gareth, EViews Moderator, EViews Jason, EViews Matt
State space specification
- Attachments
-
- tni_peru.wf1
- (56.58 KiB) Downloaded 190 times
Re: State space specification
You are experiencing three types of error in your model:
1) Signal variables are not allowed in state equation. You should drop the signal variable in your state specification:
kmc1_r.append @state sv3 = c(5) * sv3(-1) + c(6) * dl1ipcm + c(7) * sv2 + c(8) * dl1ipc_sa(+1) + [var = exp(c(5))]
2) Invalid lags or leads for state variables in state equation. You should use lagged specifications of state variables in the right hand side of all your state equations. For instance:
kmc1_r.append @state sv5 = c(11) + c(12) * sv10(-1) + c(13) * dl1itcer + c(14) * sv4(-1) + [var = exp(c(3))]
3) Matrix size error in state prior variance matrix. Since you have 14 state equations, you should extend the size of your covariance matrix:
cov_c = @identity(14)
Although you correct these errors, you may not necessarily obtain desirable results that may be arising from various reasons. Please search the forum for similar problems and advices for possible solutions.
1) Signal variables are not allowed in state equation. You should drop the signal variable in your state specification:
kmc1_r.append @state sv3 = c(5) * sv3(-1) + c(6) * dl1ipcm + c(7) * sv2 + c(8) * dl1ipc_sa(+1) + [var = exp(c(5))]
2) Invalid lags or leads for state variables in state equation. You should use lagged specifications of state variables in the right hand side of all your state equations. For instance:
kmc1_r.append @state sv5 = c(11) + c(12) * sv10(-1) + c(13) * dl1itcer + c(14) * sv4(-1) + [var = exp(c(3))]
3) Matrix size error in state prior variance matrix. Since you have 14 state equations, you should extend the size of your covariance matrix:
cov_c = @identity(14)
Although you correct these errors, you may not necessarily obtain desirable results that may be arising from various reasons. Please search the forum for similar problems and advices for possible solutions.
Re: State space specification
Thank you for your reply. I was abble to work in my specification issues.
Who is online
Users browsing this forum: No registered users and 2 guests
