全部版块 我的主页
论坛 计量经济学与统计论坛 五区 计量经济学与统计软件 Stata专版
15496 20
2011-12-10
急求Stata 牛人帮助!!!!
我想建立状态方程包含AR(2)的空间状态模型,编辑如下命令:
constraint define 1 [Lu]L.u=1
constraint define 2    e.u=1
constraint define 3 [D.lny]u=1
sspace (Lu L.u,state noconstant noerror) ///
        (u L.u L.Lu e.u,state)///
       (D.lny u D.lnk,noconstant),constraint (1/3)
请问哪里出错了?为什么总是显示"variable _cons not found
                                                      r(111); "呢?
我这样写命令的依据是模仿State space methods in Stata一文中的如下模型:
捕获.PNG
State space methods in Stata文中给出的命令如下:
(St. Louis Fed (FRED) macro data). constraint define 1 [Lf]L.f = 1. constraint define 2 [D.ipman]u1 = 1. constraint define 3 [D.income]u2 = 1. constraint define 4 [D.hours]u3 = 1. constraint define 5 [D.unemp]u4 = 1. constraint define 6 [var(f)]_cons = 1. sspace (f L.f L.Lf, state noconstant) ///> (Lf L.f, state noconstant noerror) ///> (u1 L.u1, state noconstant) ///> (u2 L.u2, state noconstant) ///> (u3 L.u3, state noconstant) ///> (u4 L.u4, state noconstant) ///> (D.ipman f u1, noconstant noerror) ///> (D.income f u2, noconstant noerror) ///> (D.hours f u3, noconstant noerror) ///> (D.unemp f u4, noconstant noerror), ///> covstate(diagonal) constraints(1/6)我现在要建立的模型类似于上述模型去掉第三个AR(1)方程,并且将f的系数固定为1 放入测量方程中,加入一个独立变量D.lnk。
求指导啊!
附件为State space methods in Stata,希望能与大家讨论。






附件列表
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

全部回复
2011-12-10 18:23:29
第二行的constraint define 2  [u]  e.u=1不知道[u]为什么总是打不上去啊!
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

2011-12-11 09:24:18
pX87dklm 发表于 2011-12-10 23:31
要思想,更要行动!
what do you mean???.?
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

2011-12-11 21:32:30
r8xDg07c 发表于 2011-12-11 12:09
谢谢楼主
怎么竟是些无厘头的人!
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

2011-12-12 16:42:38
没有下载到该模块呀 ,楼主是从公司买的吗?
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

2011-12-12 19:51:15
yexingtianma 发表于 2011-12-12 16:42
没有下载到该模块呀 ,楼主是从公司买的吗?
不是啊,从Stata11就有state space model 了,我用的是论坛上下的破解版
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

点击查看更多内容…
相关推荐
栏目导航
热门文章
推荐文章

分享

扫码加好友,拉您进群
各岗位、行业、专业交流群