sargan.fct {pdynmc} | R Documentation |
Sargan test.
Description
sargan.fct
tests the validity of the overidentifying restrictions.
Usage
sargan.fct(object)
Arguments
object |
An object of class 'pdynmc'. |
Details
The null hypothesis is that the overidentifying restrictions are valid. The test statistic is computed as proposed by Sargan (1958). As noted by Bowsher (2002) and Windmeijer (2005), the test statistic is weakened by many instruments and inconsistent in the presence of heteroscedasticity according to Roodman (2009a).
Value
An object of class 'htest' which contains the Sargan test statistic and corresponding p-value for the null hypothesis that the overidentifying restrictions are valid.
References
Bowsher CG (2002).
“On testing overidentifying restrictions in dynamic panel data models.”
Economics Letters, 77(2), 211–220.
doi:10.1016/S0165-1765(02)00130-1.
Roodman D (2009a).
“How to do xtabond2: An Introduction to Difference and System GMM in Stata.”
Stata Journal, 9(1), 86–136.
https://www.stata-journal.com/article.html?article=st0159.
Sargan JD (1958).
“The Estimation of Economic Relationships Using Instrumental Variables.”
Econometrica, 26(3), 393–415.
doi:10.2307/1907619.
Windmeijer F (2005).
“A finite sample correction for the variance of linear efficient two-step GMM estimators.”
Journal of Econometrics, 126(1), 25–51.
doi:10.1016/j.jeconom.2004.02.005.
See Also
pdynmc
for fitting a linear dynamic panel data model.
Examples
## Load data
data(ABdata, package = "pdynmc")
dat <- ABdata
dat[,c(4:7)] <- log(dat[,c(4:7)])
dat <- dat[c(140:0), ]
## Code example
m1 <- pdynmc(dat = dat, varname.i = "firm", varname.t = "year",
use.mc.diff = TRUE, use.mc.lev = FALSE, use.mc.nonlin = FALSE,
include.y = TRUE, varname.y = "emp", lagTerms.y = 2,
fur.con = TRUE, fur.con.diff = TRUE, fur.con.lev = FALSE,
varname.reg.fur = c("wage", "capital", "output"), lagTerms.reg.fur = c(1,2,2),
include.dum = TRUE, dum.diff = TRUE, dum.lev = FALSE, varname.dum = "year",
w.mat = "iid.err", std.err = "corrected", estimation = "onestep",
opt.meth = "none")
sargan.fct(m1)
## Load data
data(ABdata, package = "pdynmc")
dat <- ABdata
dat[,c(4:7)] <- log(dat[,c(4:7)])
## Further code example
m1 <- pdynmc(dat = dat, varname.i = "firm", varname.t = "year",
use.mc.diff = TRUE, use.mc.lev = FALSE, use.mc.nonlin = FALSE,
include.y = TRUE, varname.y = "emp", lagTerms.y = 2,
fur.con = TRUE, fur.con.diff = TRUE, fur.con.lev = FALSE,
varname.reg.fur = c("wage", "capital", "output"), lagTerms.reg.fur = c(1,2,2),
include.dum = TRUE, dum.diff = TRUE, dum.lev = FALSE, varname.dum = "year",
w.mat = "iid.err", std.err = "corrected", estimation = "onestep",
opt.meth = "none")
sargan.fct(m1)