- Introduced by
- Hausman (1978); robust variant after Arellano (1993)
- Year
- 1978
- Type
- Panel model specification test
What does it do?
The Robust Hausman Test is a specification test for panel-data models.
It compares fixed-effects and random-effects estimates using a variance estimate intended to remain valid under heteroscedastic and serially correlated errors, and it is used to decide which estimator is appropriate. It extends Hausman's (1978) specification test, which compares an estimator that is efficient under the null with one that is consistent under the alternative. Arellano (1993) is associated with applying this idea to correlated effects in panel data.
The intuition behind the method
In panel data you must decide whether each unit's unobserved effect is correlated with the predictors. If it is, only the fixed-effects estimator is consistent; if it is not, the random-effects estimator is consistent and more efficient. The test compares the two sets of coefficients. If they differ by more than sampling noise, the random-effects assumption is rejected and fixed effects are retained. The robust version measures that difference with a variance that allows for non-constant and clustered error variance, so the verdict is less likely to be distorted by those features of the errors.
History
The Hausman specification test, which compares an estimator that is efficient under the null with one that is consistent under the alternative, was introduced by Hausman in 1978 in Econometrica. White (1981) extended the approach to compare any two estimators, and later work generalised it to moment-based specification tests. Robust versions of the statistic, which use a heteroscedasticity-robust variance for the contrast and a generalized inverse when that variance is singular, are described in the econometrics literature and implemented in software such as the R package plm. Arellano (1993), "On the Testing of Correlated Effects with Panel Data" (Journal of Econometrics), is associated with the panel application of testing correlated unit effects.
When to use it
Choose this test when you have panel data, meaning repeated observations on the same units, and need to decide between fixed- and random-effects specifications. It is particularly relevant when the errors may be heteroscedastic or serially correlated, so that the classical Hausman test's variance assumptions are doubtful. The test requires a consistent fixed-effects estimator and a robust covariance estimate for the contrast, so the panel should have enough units for cluster-robust inference to be meaningful. No firm minimum number of units is established here; with few units, check resampling-based alternatives such as the wild bootstrap or a permutation test before relying on the chi-square p-value. It is not a suitable choice for cross-sectional data without a unit structure.
Limitations and considerations
- The test depends on the random-effects estimator being the efficient alternative under the null, and on the robust covariance of the contrast being estimated accurately; errors in that covariance feed directly into the statistic.
- With few panel units, the chi-square approximation to the Wald-type statistic is less trustworthy, so the verdict is weaker than in larger panels.
- Rejecting random effects says that the coefficients differ; it does not show which regressor or unit characteristic drives the difference unless the contrasts are examined coefficient by coefficient.
Source conditions do not replace independent scientific review or validation by an analysis engine.
Strengths
- Its robust covariance is intended to keep the comparison valid when error variances are non-constant or serially correlated, conditions under which the classical Hausman variance, which assumes the random-effects estimator is efficient, can be unreliable.
- It reduces the choice between fixed and random effects to one test of whether the unit effects are correlated with the regressors, which is the property that determines which estimator is consistent.
- The contrast involves only the coefficients that both estimators can estimate, so the test is a joint test over those coefficients rather than a comparison of the whole model.
Applications
- Choosing between fixed- and random-effects specifications in panel analyses in economics and related social sciences.
- Checking whether unobserved individual factors are correlated with explanatory variables before interpreting random-effects coefficients, as in Hausman's 1978 example of an individual wage equation.
- Panel studies with clustered or heteroscedastic errors, where the classical test's variance assumptions are doubtful.
How it works
How it works
Each observation y for unit i at time t is written as a linear function of the predictors X, plus a unit-specific effect μ_i and an idiosyncratic error ε_it. The central question is whether μ_i is correlated with the regressors X. The null hypothesis is that it is not (random-effects assumption); the alternative is that it is.
Formula
y_{it} = X_{it}\beta + \mu_i + \varepsilon_{it}The statistic contrasts the fixed-effects estimate β̂_FE, which is consistent whether or not the unit effects are correlated with X, with the random-effects estimate β̂_RE, which is efficient and consistent only when they are uncorrelated. The contrast is weighted by the inverse of a robust variance matrix V̂_robust of the difference, intended to allow for heteroscedasticity and autocorrelation. Under the null, the Wald-type quantity is asymptotically chi-square. The degrees of freedom equal the rank J of the estimated contrast variance, which is at most the number k of compared coefficients. If that matrix is singular, a generalized inverse is used and J replaces k. A large value leads to rejecting random effects in favour of fixed effects.
Formula
H = (\hat{\beta}_{FE} - \hat{\beta}_{RE})^{\top}\,\widehat{V}_{robust}^{-}\,(\hat{\beta}_{FE} - \hat{\beta}_{RE}) \overset{d}{\to} \chi^2_J, \quad J=\operatorname{rank}(\widehat{V}_{robust}) \le kCommon pitfalls
- Using the classical Hausman variance formula when errors are heteroscedastic or serially correlated. The statistic can then be unreliable or even negative, which is the reason for using the robust variance.
- Forgetting to apply robust (cluster-robust) standard errors when forming the contrast, which removes the purpose of the robust variant.
- Reading a non-significant result as proof that random effects are correct. A failure to reject only means the data do not show correlation between the unit effects and the regressors at this test's power. Random effects are more efficient only if that assumption actually holds.
- Applying the test to a very small panel and treating the verdict as settled. In such cases the test's approximation is less reliable and resampling-based alternatives should be considered.
Frequently asked questions
How is the robust Hausman test different from the classical one?
The classical Hausman test assumes the random-effects estimator is fully efficient under the null, so its variance is the simple difference of the two estimators' variances. Under heteroscedasticity or autocorrelation that assumption fails and the statistic can be unreliable or even negative. The robust version replaces that variance with a robust (cluster-robust) covariance of the contrast, giving a Wald-type chi-square statistic.
What does a significant result mean?
The null hypothesis is that the unit effects are uncorrelated with the regressors, so random effects are consistent and efficient. A large, significant statistic rejects this: the unit effects appear correlated with the predictors, and the fixed-effects estimator, which remains consistent under both hypotheses, is the safer choice. A non-significant result is consistent with random effects, which is then more efficient, but it does not prove the assumption holds.
What sample size do I need?
No firm minimum number of observations or panel units is established here. With few units the chi-square approximation is less reliable, so consider resampling alternatives such as the wild bootstrap or a permutation test; see the related pages.
Do I have to use robust standard errors?
Yes. The whole point of the robust variant is that the contrast between the fixed- and random-effects estimates is weighted by a robust covariance that allows for heteroscedasticity and autocorrelation, so a robust (cluster-robust) covariance must be used.
Related methods
Sources
Hausman, J. A. (1978). Specification Tests in Econometrics. Econometrica, 46(6), 1251-1271.
Open DOI referenceArellano, M. (1993). On the Testing of Correlated Effects with Panel Data. Journal of Econometrics, 59(1-2), 87-97.
Open DOI reference