全部版块 我的主页
论坛 计量经济学与统计论坛 五区 计量经济学与统计软件 Stata专版
22069 10
2014-03-18
数据分了2组,健康组和非健康组,做完了LOGIT regression以后,怎么对这两组数据中的每个变量的系数做T检验呢?

万分感谢啊,拜托大家了!
二维码

扫码加我 拉你入群

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

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

全部回复
2014-3-18 08:31:33
I think you can compute Wald test, but a better option may be to run the whole data together by including interaction terms using the dummy of the group in the model?
二维码

扫码加我 拉你入群

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

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

2014-3-19 05:58:30
jjjj6666 发表于 2014-3-18 08:31
I think you can compute Wald test, but a better option may be to run the whole data together by incl ...
但是现在需要对系数做T检验,导师没让我做别的检验。我知道怎么对样本做T检验,但是对系数的T检验真是一点都不会啊,您能告诉我从STATA的那里可以做嘛?我用的是LOGIT回归,在那个菜单选项里有关于这个检验的吗?多谢!
二维码

扫码加我 拉你入群

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

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

2014-3-19 06:18:30
you can use this

(b1-b2)/sqrt(se(b1)^2+se(b2)^2)

where b1 is the coefficient from the 1st logit, b2 is the corresponding coefficient from the 2nd logit.  For logit, this will be z-statistics, not t, I think(?)

I still think running the model with interaction term is a better approach.
二维码

扫码加我 拉你入群

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

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

2014-3-20 02:41:58
jjjj6666 发表于 2014-3-19 06:18
you can use this

(b1-b2)/sqrt(se(b1)^2+se(b2)^2)
真的很感谢您的回复,我不怎么熟悉STATA的COMMENTS,您知道怎么用菜单方式实现这个命令吗?多谢!
二维码

扫码加我 拉你入群

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

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

2014-3-20 03:41:41
I think you need to use command window since you need to compute yourself, for example, if g is your group variable with 0 for one of the subgroup and 1 for the others,

* run 1st logit
logit y x if g==0
* record b and SE2
mat B1=e(b)
mat V1=e(V)

* run 2nd logit
logit y x if g==1
* record b and SE2
mat B2=e(b)
mat V2=e(V)

to test the difference of coefficient for x, we compute the p-value

local p=2*(1-normprob(abs(B1[1,1]-B2[1,1])/sqrt(V1[1,1]+V2[1,1])))
di `p'


二维码

扫码加我 拉你入群

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

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

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

说点什么

分享

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