esttab中的ICC统计信息

时间:2018-09-18 18:19:17

标签: stata

我想在由 community-contributed Stata命令var fulln = listobj.shortn;生成的表中,包括我的混合模型的var fulln = listobj[shorn]统计信息。

例如:

esttab

鉴于此是用不同的方法计算的,我该怎么办 我估计模型后输入命令?

1 个答案:

答案 0 :(得分:2)

您需要在estadd之后使用estat来插入相关的r()标量:

webuse nlswork, clear
eststo clear

mixed ln_w grade age c.age#c.age ttl_exp tenure c.tenure#c.tenure || id:
eststo model

estat icc
estadd scalar ICC = `r(icc2)'

esttab model, label star(* 0.05 ** 0.001 *** 0.0001) b(%9.4f) mtitles aic bic ///
scalars(ICC ll chi2_c p_c k_f k_r)

上面将产生所需的输出:

------------------------------------
                              (1)   
                           model1   
------------------------------------
ln(wage/GNP deflat~)                
current grade comp~d       0.0708***
                          (39.42)   

age in current year        0.0318***
                          (11.71)   

age in current yea~r      -0.0007***
                         (-14.48)   

total work experie~e       0.0352***
                          (30.95)   

job tenure, in years       0.0371***
                          (23.63)   

job tenure, in yea~r      -0.0018***
                         (-18.15)   

Constant                   0.1472** 
                           (3.29)   
------------------------------------
lns1_1_1                            
Constant                  -1.3185***
                         (-97.34)   
------------------------------------
lnsig_e                             
Constant                  -1.2302***
                        (-265.96)   
------------------------------------
Observations                28099   
AIC                      1.83e+04   
BIC                      1.84e+04   
ICC                        0.4560   
ll                      -9.15e+03   
chi2_c                  8802.1857   
p_c                        0.0000   
k_f                        7.0000   
k_r                        2.0000   
------------------------------------
t statistics in parentheses
* p<0.05, ** p<0.001, *** p<0.0001