Search code examples
reportpanelplm

Heteroskedasticity random effects regression with the plm package (correction & how to report)


I have already checked a couple of topics and also found some help regarding heteroskedasticity in panel regressions. But unfortunately, some questions have remained unsolved.

Following example (some repeated measures, data already in long format):

Panelregr <- plm(V1~ V2 + V3 + V4, data = XY,  model ="random")

Then I checked for heteroskedasticity:

B.P.Test <- bptest(V ~ V2 + V3 + V4, data=XY, studentize = F)

The test was highly significant --> heteroskedasticity

Then I read (Link: https://www.princeton.edu/~otorres/Panel101R.pdf) about using robust covariance matrix to account for hetereoskedasticity. For the example above I used the code

coeftest(Panelregr, vcovHC)
summary(Panelregr, vcov = vcovHC)

and got the results. But I could also use coeftest(Panelregr, vcovHC(Panelregr, type = "HC3")) or the other types HC0 - HC4

Now some questions came up:

  1. Which estimator of these five types do I receive when I use coeftest(Panelregr, vcovHC) instead of defining one particular HC..? Is it HC0?

  2. How do I know which HC... fits to my data? (I read some information, for example: https://cran.r-project.org/web/packages/sandwich/vignettes/sandwich.pdf , page 4, but I´m still not sure how to decide).

  3. How do I describe the results in case of the use of one of these correct estimators? Example: "In order to account for heteroskedasticity, a robust covariance metrix was used. In detail, we used the HC... estimator as ... In the following table, the results of the HC... estimator are shown."

  4. When I correct for hetereosk. , the results don´t include values like R-squared. Is it correct to report the corrected values (e.g. coeftest(Panelregr, vcovHC) and to report values like R-squared from the "originial" Panel regression (Panelregr <- plm(V1~ V2 + V3 + V4, data = XY, model ="random"))?


Solution

  • 1) The default one (see ?vcovHC) and for plm::vcovHC that is HC0 as it is the first value mentioned for argument type.

    3) HC0, HC1, ... are scaling factors for the variance-covariance matrix. Good to mentioned that. You also want to mention the estimator, i.e. what is given by the method argument. A typical choice is the estimator by Arellano (1987) and it is the default for plm::vcovHC.

    4) The R^2 is not impacted by using a het.-consistent variance-covariance matrix. However, the F-statistic is. summary(Panelregr, vcov = vcovHC) gives you what you need.