全部版块 我的主页
论坛 计量经济学与统计论坛 五区 计量经济学与统计软件 Stata专版
9718 16
2012-10-18
学生大学成绩(GPA)做因变量,高考成绩(gkscore)、同宿舍舍友的大学成绩均值(mdepgpa)、家庭经济社会地位(SES)做自变量。回归过程中,用同宿舍舍友的高考成绩均值(mdepgkscore)作为舍友大学成绩均值的工具变量,命令是:
ivreg  GPA  gkscore  SES (mdepgpa=mdepgkscore),
但是,如果我想再加入学生所在省(shengcode,1-31代表各省)做哑变量,变成变截距模型来控制各省的差异,可是ivreg是不支持“absorb()”的,这该怎么办呢??
请教各位啦

二维码

扫码加我 拉你入群

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

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

全部回复
2012-10-18 00:24:59
in stata 12, there is only ivregress, thus in stata12 i will use

ivregress  2sls GPA  gkscore  SES  i.province(mdepgpa=mdepgkscore)
二维码

扫码加我 拉你入群

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

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

2012-10-18 00:32:57
fgleric 发表于 2012-10-18 00:24
in stata 12, there is only ivregress, thus in stata12 i will use

ivregress  2sls GPA  gkscore  SE ...
谢谢您的解答!下表是回归的结果,可是我看到的一篇论文报告哑变量为0的F检验值为0.0000,表明各省差异是显著的。 那么我应该如何看这个回归省哑变量为0 的F检验值呢?

       
stdGPA       Coef.   Std. Err.      t    P>t     [95% Conf. Interval]
       
mdepgpa   -.5800456   .3913925    -1.48   0.139    -1.347885    .1877939
SES    .0598781   .0325819     1.84   0.066    -.0040415    .1237977
stdgk    .0609832    .015846     3.85   0.000     .0298963    .0920702
_Ishengco~_2    .2732034   .3190114     0.86   0.392    -.3526379    .8990447
_Ishengco~_3    .1842334   .3066896     0.60   0.548    -.4174348    .7859015
_Ishengco~_4    .5296653   .3251515     1.63   0.104    -.1082218    1.167552
_Ishengco~_5   -.0350153   .3233923    -0.11   0.914    -.6694511    .5994204
_Ishengco~_6   -.1062792   .3492471    -0.30   0.761    -.7914374     .578879
_Ishengco~_7   -.4766509   .3478044    -1.37   0.171    -1.158979     .205677
_Ishengco~_8    .1165017   .3223722     0.36   0.718    -.5159327    .7489362
_Ishengco~_9    .1427283   .4675832     0.31   0.760    -.7745834     1.06004
_Ishengco~10    .4343926   .3060715     1.42   0.156    -.1660629    1.034848
_Ishengco~11    .3457941   .3001757     1.15   0.250     -.243095    .9346832
_Ishengco~12    .1988101   .3144706     0.63   0.527    -.4181229     .815743
_Ishengco~13    .1215926   .2528206     0.48   0.631    -.3743946    .6175798
_Ishengco~14    .5094285   .2952234     1.73   0.085    -.0697452    1.088602
_Ishengco~15   -.0349507   .2982426    -0.12   0.907    -.6200475    .5501461
_Ishengco~16    .3985534   .2863567     1.39   0.164    -.1632254    .9603321
_Ishengco~17    .2926448   .2884858     1.01   0.311    -.2733108    .8586005
_Ishengco~18    .5526814   .2967185     1.86   0.063    -.0294252    1.134788
_Ishengco~19    .0412893   .3120518     0.13   0.895    -.5708985    .6534772
_Ishengco~20   -.1469805   .3313913    -0.44   0.657    -.7971087    .5031478
_Ishengco~21   -.6341297   .3551105    -1.79   0.074    -1.330791    .0625314
_Ishengco~22    .2367155   .3305196     0.72   0.474    -.4117028    .8851338
_Ishengco~23    .9442135   .3036048     3.11   0.002     .3485971     1.53983
_Ishengco~24   -.1192263   .3401941    -0.35   0.726    -.7866241    .5481716
_Ishengco~25   -.1306168   .3031145    -0.43   0.667    -.7252712    .4640376
_Ishengco~26    .1847967    .572571     0.32   0.747    -.9384815    1.308075
_Ishengco~27    .2736236   .3256775     0.84   0.401    -.3652953    .9125424
_Ishengco~28    .6050667    .339592     1.78   0.075    -.0611499    1.271283
_Ishengco~29    .1027377   .3963521     0.26   0.796    -.6748317     .880307
_Ishengco~30    .2580268   .5058057     0.51   0.610    -.7342702    1.250324
_Ishengco~31    .0851456   .3054431     0.28   0.780    -.5140771    .6843683
gen1    .5649874   .1332588     4.24   0.000     .3035583    .8264165
_cons   -5.268566   1.293457    -4.07   0.000     -7.80609   -2.731042
       
Instrumented:        mdepgpa
Instruments:        SES stdgk _Ishengcode_2 _Ishengcode_3 _Ishengcode_4
        _Ishengcode_5 _Ishengcode_6 _Ishengcode_7 _Ishengcode_8
        _Ishengcode_9 _Ishengcode_10 _Ishengcode_11 _Ishengcode_12
        _Ishengcode_13 _Ishengcode_14 _Ishengcode_15 _Ishengcode_16
        _Ishengcode_17 _Ishengcode_18 _Ishengcode_19 _Ishengcode_20
        _Ishengcode_21 _Ishengcode_22 _Ishengcode_23 _Ishengcode_24
        _Ishengcode_25 _Ishengcode_26 _Ishengcode_27 _Ishengcode_28
        _Ishengcode_29 _Ishengcode_30 _Ishengcode_31 gen1 mstdepgk
       
二维码

扫码加我 拉你入群

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

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

2012-10-18 00:38:23
fgleric 发表于 2012-10-18 00:24
in stata 12, there is only ivregress, thus in stata12 i will use

ivregress  2sls GPA  gkscore  SE ...
如果用
areg  GPA gkscoe  ses mdepgpa, absorb(shengcode),结果是
Linear regression, absorbing indicators                        Number of obs =    1318
                        F(  2,  1285) =   49.98
                        Prob > F      =  0.0000
                        R-squared     =  0.1225
                        Adj R-squared =  0.1007
                        Root MSE      =  .92428

                       
stdGPA       Coef.   Std. Err.        t        P>t        [95% Conf. Interval]
                       
stdgk    .0610338   .0136607        4.47        0.000        .0342341    .0878335
mdepgpa     .356594   .0399913        8.92        0.000        .2781386    .4350493
_cons   -4.927626   1.120312        -4.40        0.000        -7.125467   -2.729785
                       
shengcode        F(30, 1285) =        2.323        0.000        (31 categories)
,倒是可以看到shengcode F值是0,可是这样就无法使用ivregress了
二维码

扫码加我 拉你入群

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

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

2012-10-18 01:47:51
fgleric 发表于 2012-10-18 00:24
in stata 12, there is only ivregress, thus in stata12 i will use

ivregress  2sls GPA  gkscore  SE ...
求教,stata如何对虚拟变量回归系数进行对模型的F检验?也就是检验至少一个虚拟变量系数不为0的假设?
二维码

扫码加我 拉你入群

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

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

2012-10-18 05:22:34
如何你想看dummy是否显著,即省际效应是否显著,那为什么要设置省份dummy呢?

所以可否说明一下:你是想控制省份效应(仅设置dummy),可是想研究省份效应(需要交叉项)
二维码

扫码加我 拉你入群

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

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

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

说点什么

分享

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