David - 2 months ago 34

R Question

I am running a panel data regression using the

`plm`

`R`

I know there is the

`vif()`

`car`

The

`plm`

Is there a way to calculate a similar test to

`vif`

`car`

I cannot disclose the data, but the problem should be relevant to all panel data models.

The dimension is roughly 1,000 observations, over 50 time-periods.

The code I use looks like this:

`pdata <- plm.data(RegData, index=c("id","time"))`

fixed <- plm(Y~X, data=pdata, model="within")

and then

`vif(fixed)`

returns an error.

Thank you in advance.

Answer

This question has been asked with reference to other statistical packages such as SAS https://communities.sas.com/thread/47675 and Stata http://www.stata.com/statalist/archive/2005-08/msg00018.html and the common answer has been to use pooled model to get VIF. The logic is that since multicollinearity is only about independent variable there is no need to control for individual effects using panel methods.