plmtest {plm} | R Documentation |
Test of individual and/or time effect for panel models.
plmtest(x, ...) ## S3 method for class 'plm': plmtest(x,effect="id",type="bp", ...) ## S3 method for class 'plms': plmtest(x,effect="id",type="bp", ...) ## Default S3 method: plmtest(x,n=NULL,T=NULL,balanced=NULL,id=NULL,time=NULL,effect="id",type="bp",data=NULL, ...)
x |
a vector of residuals for the default method, |
effect |
a character string indicating which effects are tested :
individual effects ("id" ), time effects ("time" ) or both ("double" ), |
type |
a character string indicating the test to be
computed : "bp" for Breush-Pagan (1980), "ghm" for Gourieroux, Holly and
Monfort (1982), "honda" for Honda (1985) or "kw" for King and Wu (1997), |
n |
the number of individuals, |
T |
the number of time periods, |
balanced |
A logical value indicating wheter the panel is balanced or not, |
id |
a vector containing the individual index, |
time |
a vector containong the time index, |
data |
the name of the data, |
... |
further arguments. |
These Lagrange multiplier tests use only the residuals of the pooling
model. The main argument of this function may be whether a vector of
residuals, a pooling model of class plm
or an object of class plms
.
An object of class "htest"
.
Breusch, T.S. and A.R. Pagan (1980), The Lagrange multiplier test and its applications to model specification in econometrics, Review of Economic Studies, 47, pp.239–253.
Gourieroux, C., A. Holly and A. Monfort (1982), Likelihood ratio test, Wald test, and Kuhn–Tucker test in linear models with inequality constraints on the regression parameters, Econometrica, 50, pp.63–80.
Honda, Y. (1985), Testing the error components model with non–normal disturbances, Review of Economic Studies, 52, pp.681–690.
King, M.L. and P.X. Wu (1997), Locally optimal one–sided tests for multiparameter hypotheses, Econometric Reviews, 33, pp.523–529.
pFtest
for individual and/or time effects tests based on
the within model.
library(Ecdat) data(Grunfeld) Grunfeld <-pdata.frame(Grunfeld,firm,year) g <- plm(inv ~ value + capital, data=Grunfeld) plmtest(g) plmtest(g,effect="time") plmtest(g,type="honda") plmtest(g,type="ghm",effect="double") plmtest(g,type="kw",effect="double")