是否可以从标准化数据的分位数回归中解释系数?
假设我标准化因变量和自变量(减去平均值并除以标准差)然后对中位数进行分位数回归,例如
qreg y x, q(0.5)
在状态。自变量的估计系数为. 那么下面的解释是否正确:
自变量增加一个标准差,因变量的中位数增加标准差?
是否可以从标准化数据的分位数回归中解释系数?
假设我标准化因变量和自变量(减去平均值并除以标准差)然后对中位数进行分位数回归,例如
qreg y x, q(0.5)
在状态。自变量的估计系数为. 那么下面的解释是否正确:
自变量增加一个标准差,因变量的中位数增加标准差?
是的,这就是解释。您可以看到这一点的一种方法是通过预测标准化的不同值的中位数,每个 1 单位(在本例中为标准差)appart。你可以看看这些预测的中位数有多少不同,你会发现这与你的标准化分位数回归系数完全相同。这是一个例子:
. sysuse auto, clear
(1978 Automobile Data)
.
. // standardize variables
. sum price if !missing(price,weight)
Variable | Obs Mean Std. Dev. Min Max
-------------+--------------------------------------------------------
price | 74 6165.257 2949.496 3291 15906
. gen double z_price = ( price - r(mean) ) / r(sd)
.
. sum weight if !missing(price,weight)
Variable | Obs Mean Std. Dev. Min Max
-------------+--------------------------------------------------------
weight | 74 3019.459 777.1936 1760 4840
. gen double z_weight = ( weight - r(mean) ) / r(sd)
.
. // estimate the quartile regression
. qreg z_price z_weight
Iteration 1: WLS sum of weighted deviations = 47.263794
Iteration 1: sum of abs. weighted deviations = 54.018868
Iteration 2: sum of abs. weighted deviations = 43.851751
Median regression Number of obs = 74
Raw sum of deviations 48.21332 (about -.41744651)
Min sum of deviations 43.85175 Pseudo R2 = 0.0905
------------------------------------------------------------------------------
z_price | Coef. Std. Err. t P>|t| [95% Conf. Interval]
-------------+----------------------------------------------------------------
z_weight | .2552875 .1368752 1.87 0.066 -.0175682 .5281432
_cons | -.3415908 .1359472 -2.51 0.014 -.6125966 -.070585
------------------------------------------------------------------------------
.
. // predict the predicted median for z_weight
. // is -2, -1, 0, 1, 2
. drop _all
. set obs 5
obs was 0, now 5
. gen z_weight = _n - 3
. predict med
(option xb assumed; fitted values)
. list
+----------------------+
| z_weight med |
|----------------------|
1. | -2 -.8521658 |
2. | -1 -.5968783 |
3. | 0 -.3415908 |
4. | 1 -.0863033 |
5. | 2 .1689841 |
+----------------------+
.
. // compute how much the predicted median
. // differs between cars 1 standard deviation
. // weight apart
. gen diff = med - med[_n - 1]
(1 missing value generated)
. list
+---------------------------------+
| z_weight med diff |
|---------------------------------|
1. | -2 -.8521658 . |
2. | -1 -.5968783 .2552875 |
3. | 0 -.3415908 .2552875 |
4. | 1 -.0863033 .2552875 |
5. | 2 .1689841 .2552875 |
+---------------------------------+