我估计一个连续变量在某个因子水平上的边际效应。虽然我可以为因子变量定义和更改值标签,但 margins 命令不会显示这些标签。这可以改变吗?
* load data
set more off
use http://www.stata-press.com/data/r13/nlswork
describe
* set panel structure
xtset idcode year
* set labels
label define OCC_labels 1 "First" 2 "Second" 3 "Third"
label values occ_code OCC_labels
tab occ_code
* fixed effects regression, with interaction of continuous and factor variable
xtreg ln_wage c.wks_ue##i.occ_code, fe
* investigate marginal effects of weeks worked last year
margins, dydx(wks_ue) at(occ_code = (1 2 3))