I have a dateset that includes information on U.S. states in 1987, 1990 and 1993 and describes the relationship between murder rate and the death penalty. mrdrte is the number of murders per 100,000 population, exec is the number of total executions in past 3 years, and unem is an unemployment rate. We model: $$mrdrte_{it} = \beta_0 + \beta_1 exec_{it} + \beta_2 unem_{it}+a_i+u_{it}$$
Below I have labelled my question in bold and big font. I do not know how to proceed with my analysis without answering them.
Descriptives
. xtsum mrdrte exec unem
Variable | Mean Std. Dev. Min Max | Observations
-----------------+--------------------------------------------+----------------
mrdrte overall | 8.070588 9.192867 .8 78.5 | N = 153
between | 8.768838 1.333333 64.16667 | n = 51
within | 2.93735 -19.89608 22.40392 | T = 3
| |
exec overall | 1.228758 3.791432 0 34 | N = 153
between | 3.440601 0 22.33333 | n = 51
within | 1.641031 -10.10458 12.89542 | T = 3
| |
unem overall | 5.973203 1.680617 2.2 12 | N = 153
between | 1.316781 3.233333 9.966667 | n = 51
within | 1.055167 3.573203 9.439869 | T = 3
Question: max and min look strange, how can the be like that?
Is overall - between - within = 0 ? We check using R.
> 1.680617^2-1.316781^2-1.055167^2
[1] -0.0228161
> 3.791432^2-3.440601^2-1.641031^2
[1] -0.1557614
> 9.192867^2-8.768838^2-2.93735^2
[1] -1.011741
No. Why not?
Question: The sum is not 0. Is this a sign of an error?
Between is between different id's (i.e. we fix $t$ and move $i$). We have $n=51$ different id's, so $i$ go from 1 to 51. For example between different id's the Std.Dev. for $mrdrte$ (murder rate) is $8.768838$. Between different id's the exec Std.Dev. is $3.791432$.
Within is within the same id, over time (i.e. we fix $i$ and move $t$). We have $T=4$ time periods, so $t$ go from 1 to 4. For example within $mrdrte$ Std.Dev is $2.93735 < 8.768838$ so apparently between different id's. varies mor than within individuals over time. We can conclude that $mrdrte$ varies more between different id's than within the same one. So adding another $n$ gives, loosely speaking, more information than adding another time period $T$ and this is good for our analysis since in this dataset $n>T$.
Question: How can we have zero variation in the table? What is the reason here?
By looking at these numbers, we can conclude there is a large portion of between variation in the data. This will be important later on when choosing FE or RE.
Should we use FE or RE?
In practice you could run them both and see if they differ, and if not - we need not worry about the choice. We run them both and report the output below. I set $i$ to be id and $t$ to be year.
. xtset id year
. xtreg mrdrte exec unem, fe
Fixed-effects (within) regression Number of obs = 153
Group variable: id Number of groups = 51
R-sq: within = 0.0047 Obs per group: min = 3
between = 0.0007 avg = 3.0
overall = 0.0002 max = 3
F(2,100) = 0.24
corr(u_i, Xb) = -0.0635 Prob > F = 0.7909
------------------------------------------------------------------------------
mrdrte | Coef. Std. Err. t P>|t| [95% Conf. Interval]
-------------+----------------------------------------------------------------
exec | -.1140743 .1800836 -0.63 0.528 -.4713551 .2432065
unem | .095914 .2800721 0.34 0.733 -.4597411 .6515692
_cons | 7.637844 1.684436 4.53 0.000 4.295971 10.97972
-------------+----------------------------------------------------------------
sigma_u | 8.788124
sigma_e | 3.612922
rho | .85542114 (fraction of variance due to u_i)
------------------------------------------------------------------------------
F test that all u_i=0: F(50, 100) = 16.46 Prob > F = 0.0000
. xtreg mrdrte exec unem, re
Random-effects GLS regression Number of obs = 153
Group variable: id Number of groups = 51
R-sq: within = 0.0015 Obs per group: min = 3
between = 0.0732 avg = 3.0
overall = 0.0433 max = 3
Wald chi2(2) = 0.90
corr(u_i, X) = 0 (assumed) Prob > chi2 = 0.6369
------------------------------------------------------------------------------
mrdrte | Coef. Std. Err. z P>|z| [95% Conf. Interval]
-------------+----------------------------------------------------------------
exec | -.0351956 .1619968 -0.22 0.828 -.3527036 .2823124
unem | .2560543 .2708762 0.95 0.345 -.2748532 .7869619
_cons | 6.584371 2.001338 3.29 0.001 2.661819 10.50692
-------------+----------------------------------------------------------------
sigma_u | 8.1923983
sigma_e | 3.612922
rho | .83717807 (fraction of variance due to u_i)
------------------------------------------------------------------------------
.
They are not similar. So which one can we take?
There are two kinds of variation in the data: within and between. FE uses only within. RE within and between and weighs them in a smart way, and the close $\hat \theta$ is to 1 the closer RE is to FE (when $\hat \theta = 1 \implies FE=RE.)$
In our case, $\hat \theta = .83717807$ (rho in stata output) and the closer it is to 1, the closer is RE to FE. %källa s34 0.83 is pretty high. So this is piece of evidence for using RE. %qq is this really the $\theta$ or is the output telling me something else?
Remember from above that a large portion of between variation in the data. This is another piece of evidence for using RE.
Recall our model. In RE we assume $Cov( exec_{it} , a_i ) = 0$ and $Cov( unem_{it} , a_i ) = 0$. This is rarely the case, but do we violate this assumption? The correlation is weak - Stata reports that $corr = -0.0635$
Question: is this large or small? but more importantly - is this the correlation I'm really interested in checking?
It is close to zero so the assumptions is almost fulfilled.
Did this choice of RE matter? Yes it did. The output is different, of course, but more importantly we know in general that if the RE assumptions are fulfilled then (a) $se(\hat \beta_{RE}) < se(\hat \beta_{FE})$ because it uses between-variation as well and (b) we are able to use time dependent variables in our model if we wish (remember that FE removes this opportunity since we average over all values of $t$ in order to remove the fixed effect $a_i$).