In R, plm’s vcovHC throws the obscure error “Error in tind[[i]] : subscript out of bounds” when model is iffted by first-differences
I am pretty used to using R’s plm
package to fit models with panel data, including first difference models. Today, however, I found myself facing a strange error that is thrown when passing the results of a plm
model fitted with first-differences to plm
‘s vcovHC()
function to estimated robust variance-covariance matrices: