1

I can estimate robust standard errors for a FE model using plm(), but not for a Hausman-Taylor (HT). I need the HT estimator to include in my model some time invariant variables, which reflect initial conditions. See below an example using the Cigar data.

data(Cigar, packege = "plm")

First, I create time invariant variables for initial conditions in year 63

help.sales <- subset(Cigar, year == 63, select=c(state, sales))
names(help.sales)[2]<-"sales.63" 
help.price <- subset(Cigar, year == 63, select=c(state, price))
names(help.price)[2]<-"price.63"   #rename
Cigar <-merge(Cigar, help.sales, by = "state")
Cigar <-merge(Cigar, help.price, by = "state")

Then I estimate the FE model:

FE.Cigar <- plm(price ~ sales.63:year  + ndi + factor(year) |
                sales.63:year + sales.63 + ndi + factor(year), data = Cigar, 
                model="within", effect = "individual", index = c("state","year"))

and the HT model:

HT.Cigar <- plm(price ~ sales.63:year + sales.63 + price.63 + ndi + factor(year) |
                   sales.63:year + sales.63 + ndi + factor(year), data = Cigar,
                   model="random", random.method ="ht", inst.method = "baltagi", 
                   effect = "individual", index = c("state", "year"), na.action = na.exclude)

While the robust standard errors can be estimated without any problems with the below for the FE:

coeftest(FE.Cigar, vcov.=function(x) vcovHC(x, type="sss", cluster="group"))

when I try to do the same for the HT

coeftest(HT.Cigar, vcov.=function(x) vcovHC(x, type="sss", cluster="group"))

I receive the following error message: enter image description here

A similar problem was indicated here, but given that that post is 5 years old, I was wondering if there are any solutions.

et_
  • 179
  • 8
  • Following the solution from the [link](https://stackoverflow.com/questions/25869582/robust-standard-error-estimation-for-the-hausman-taylor-estimator-using-plm-an) you posted what about using an `adhoc` funciton like the one Roger Koenker has in his [website](http://www.econ.uiuc.edu/~econ508/R/e-ta11_R.html) for the HT estimator and use that to cluster your SE. – Naus Jun 14 '19 at 17:12

0 Answers0