我正在运行一个带有一个连续变量和一个虚拟变量之间相互作用的概率回归。系数显示在回归输出中,但当我查看边际效应时,缺少交互。
如何获得交互变量的边际效应?
probit move_right c.real_income_change_percent##i.gender
Iteration 0: log likelihood = -345.57292
Iteration 1: log likelihood = -339.10962
Iteration 2: log likelihood = -339.10565
Iteration 3: log likelihood = -339.10565
Probit regression Number of obs = 958
LR chi2(3) = 12.93
Prob > chi2 = 0.0048
Log likelihood = -339.10565 Pseudo R2 = 0.0187
-----------------------------------------------------------------------------------------------------
move_right | Coef. Std. Err. z P>|z| [95% Conf. Interval]
------------------------------------+----------------------------------------------------------------
real_income_change_percent | .0034604 .0010125 3.42 0.001 .001476 .0054448
|
gender |
Female | .0695646 .1139538 0.61 0.542 -.1537807 .2929099
|
gender#c.real_income_change_percent |
Female | -.0039908 .0015254 -2.62 0.009 -.0069805 -.0010011
|
_cons | -1.263463 .0798439 -15.82 0.000 -1.419954 -1.106972
-----------------------------------------------------------------------------------------------------
margins, dydx(*) post
Average marginal effects Number of obs = 958
Model VCE : OIM
Expression : Pr(move_right), predict()
dy/dx w.r.t. : real_income_change_percent 1.gender
--------------------------------------------------------------------------------------------
| Delta-method
| dy/dx Std. Err. z P>|z| [95% Conf. Interval]
---------------------------+----------------------------------------------------------------
real_income_change_percent | .0002846 .0001454 1.96 0.050 -4.15e-07 .0005697
|
gender |
Female | -.0102626 .0207666 -0.49 0.621 -.0509643 .0304392
--------------------------------------------------------------------------------------------
Note: dy/dx for factor levels is the discrete change from the base level.
答案 0 :(得分:2)
你的问题对我来说很奇怪。您询问了虚拟虚拟交互,但您的示例涉及连续虚拟交互。
以下是如何进行其中任何一项:
webuse union, clear
/* dummy-dummy iteraction */
probit union i.south##i.black grade, nolog
margins r.south#r.black
/* continuous-dummy iteraction */
probit union i.south##c.grade
margins r.south, dydx(grade)
您应该尝试通过“手”(使用predict
s的差异)重现这些,以了解边缘命令在幕后执行的操作。
答案 1 :(得分:1)
这听起来像是一个软件(Stata)特有的问题,因此关闭投票,但这里潜伏着一个统计问题:交互效应的边际效应会是什么样的?
这种边际效应并非微不足道,而且往往强烈依赖其他协变量的价值,见this article。通常这种边际效应是如此变化,以至于尝试用一个数字来概括它是没有意义的。在我看来,这是一个主要的弱点。在一般情况下,我倾向于使用逻辑回归并将交互项解释为比值比的比率,请参阅this article。