R: Robust Covariance Matrix Estimators

vcovHC {plm} | R Documentation

## Robust Covariance Matrix Estimators

### Description

Robust covariance matrix estimators a la White for panel models.

### Usage

    ## S3 method for class 'plm'
    vcovHC(x, method = c("arellano", "white1", "white2"),
                            type = c("HC0", "sss", "HC1", "HC2", "HC3", "HC4"),
                            cluster = c("group", "time"), ...)
    ## S3 method for class 'pgmm'
    vcovHC(x, ...)

### Arguments

`x` | an object of class `"plm"` which should be the result of a random effects or a within model or a model of class `"pgmm"` or an object of class `"pcce"`,
`method` | one of `"arellano"`, `"white1"`, `"white2"`,
`type` | one of `"HC0"`, `"sss"`, `"HC1"`, `"HC2"`, `"HC3"`, `"HC4"`,
`cluster` | one of `"group"`, `"time"`
`...` | further arguments.

### Details

`vcovHC` is a function for estimating a robust covariance matrix of parameters for a fixed effects or random effects panel model according to the White method (White 1980, 1984; Arellano 1987). Observations may be clustered by `"group"` (`"time"`) to account for serial (cross-sectional) correlation.

All types assume no intragroup (serial) correlation between errors and allow for heteroskedasticity across groups (time periods). As for the error covariance matrix of every single group of observations, `"white1"` allows for general heteroskedasticity but no serial (cross–sectional) correlation; `"white2"` is `"white1"` restricted to a common variance inside every group (time period) (see Greene (2003, Sec. 13.7.1-2; 2012, Sec. 11.6.1-2) and Wooldridge (2002), Sec. 10.7.2); `"arellano"` (see ibid. and the original ref. Arellano (1987)) allows a fully general structure w.r.t. heteroskedasticity and serial (cross–sectional) correlation.

Weighting schemes are analogous to those in `vcovHC` in package sandwich and are justified theoretically (although in the context of the standard linear model) by MacKinnon and White (1985) and Cribari-Neto (2004) (see Zeileis (2004)).

The main use of `vcovHC` is to be an argument to other functions, e.g. for Wald–type testing: argument `vcov.` to `coeftest()`, argument `vcov` to `waldtest()` and other methods in the `lmtest` package; and argument `vcov.` to `linearHypothesis()` in the car package (see the examples). Notice that the `vcov` and `vcov.` arguments allow to supply a function (which is the safest) or a matrix (see Zeileis (2004), 4.1-2 and examples below).

A special procedure for `pgmm` objects, proposed by Windmeijer (2005), is also provided.

### Value

An object of class `"matrix"` containing the estimate of the asymptotic covariance matrix of coefficients.

### Author(s)

Giovanni Millo & Yves Croissant

### References

Arellano, M. (1987) Computing robust standard errors for within-group estimators, Oxford Bulletin of Economics and Statistics, 49(4), pp. 431–434.

Cribari-Neto, F. (2004) Asymptotic inference under heteroskedasticity of unknown form. Computational Statistics & Data Analysis 45(2), pp. 215–233.

Greene, W. H. (2003) Econometric Analysis, 5th ed., Prentice Hall/Pearson, Upper Saddle River, New Jersey.

Greene, W. H. (2012) Econometric Analysis, 7th ed., Prentice Hall/Pearson, Upper Saddle River, New Jersey.

MacKinnon, J. G. and White, H. (1985) Some heteroskedasticity-consistent covariance matrix estimators with improved finite sample properties. Journal of Econometrics 29(3), pp. 305–325.

Windmeijer, F. (2005) A finite sample correction for the variance of linear efficient two–step GMM estimators, Journal of Econometrics, 126(1), pp. 25–51.

White, H. (1980) Asymptotic Theory for Econometricians, Ch. 6, Academic Press, Orlando (FL).

White, H. (1984) A heteroskedasticity-consistent covariance matrix and a direct test for heteroskedasticity. Econometrica 48(4), pp. 817–838.

Wooldridge, J. M. (2002) Econometric Analysis of Cross Section and Panel Data, MIT Press, Cambridge (MA).

Zeileis, A. (2004) Econometric Computing with HC and HAC Covariance Matrix Estimators. Journal of Statistical Software, 11(10), pp. 1–17. URL http://www.jstatsoft.org/v11/i10/.

### See Also

`vcovHC` from the sandwich package for weighting schemes (`type` argument).

### Examples

    library(lmtest)
    library(car)
    data("Produc", package = "plm")
    zz <- plm(log(gsp) ~ log(pcap) + log(pc) + log(emp) + unemp,
              data = Produc, model = "random")
    ## standard coefficient significance test
    coeftest(zz)
    ## robust significance test, cluster by group
    ## (robust vs. serial correlation)
    coeftest(zz, vcov.=vcovHC)
    ## idem with parameters, pass vcov as a function argument
    coeftest(zz, vcov.=function(x) vcovHC(x, method="arellano", type="HC1"))
    ## idem, cluster by time period
    ## (robust vs. cross-sectional correlation)
    coeftest(zz, vcov.=function(x) vcovHC(x, method="arellano",
     type="HC1", cluster="group"))
    ## idem with parameters, pass vcov as a matrix argument
    coeftest(zz, vcov.=vcovHC(zz, method="arellano", type="HC1"))
    ## joint restriction test
    waldtest(zz, update(zz, .~.-log(emp)-unemp), vcov=vcovHC)
    ## test of hyp.: 2*log(pc)=log(emp)
    linearHypothesis(zz, "2*log(pc)=log(emp)", vcov.=vcovHC)

    ## Robust inference for GMM models
    data("EmplUK", package="plm")
    ar <- pgmm(dynformula(log(emp) ~ log(wage) + log(capital) + log(output),
               list(2, 1, 2, 2)), data = EmplUK, effect = "twoways",
               model = "twosteps", gmm.inst = ~ log(emp),
               lag.gmm = list(c(2, 99)))
    rv <- vcovHC(ar)
    mtest(ar, order = 2, vcov = rv)

[Package plm version 1.6-5 Index]