Is there a predict function for PLM in R?

r plm
Ram Ahluwalia picture Ram Ahluwalia · Aug 19, 2011 · Viewed 12.3k times · Source

I have a small N large T panel which I am estimating via plm (panel linear regression model), with fixed effects.

Is there any way to get predicted values for a new dataset? (I want to estimate parameters on a subset of my sample, and then use these to calculate model-implied values for the whole sample).

Thanks!

Answer

IRTFM picture IRTFM · Aug 20, 2011

There are (at least) two methods in the package to produce estimates from plm objects:

-- fixef.plm: Extract the Fixed Effects

-- pmodel.response: A function to extract the model.response

It appears to me that the author(s) are not interested in providing estimates for the "random effects". It may be a matter of "if you don't know how to do it on your own, then we don't want to give you a sharp knife to cut yourself too deeply."