lmtest
Lagrange multiplier test of model specification
Syntax
Description
returns a logical value with the rejection decision from conducting a Lagrange multiplier test
of model specification at the 5% significance level.
h
= lmtest(score
,ParamCov
,dof
)lmtest
constructs the test statistic using the input
evaluated score function, estimated parameter covariance, and degrees of
freedom.
returns the rejection decision of the Lagrange multiplier test conducted at an input
significance level.h
= lmtest(score
,ParamCov
,dof
,alpha
)
If the input evaluated score function and estimated parameter covariance are length k cell arrays, all other arguments must be length k vectors or scalars.
lmtest
treats each cell as a separate test, and returns a vector of rejection decisions.If the input evaluated score function is a row cell array,
lmtest
returns a row vector.
Examples
Input Arguments
Output Arguments
More About
Tips
lmtest
requires the unrestricted model score and parameter covariance estimator evaluated at parameter estimates for the restricted model. For example, to compare competing, nestedarima
models:Analytically compute the score and parameter covariance estimator based on the innovation distribution.
Use
estimate
to estimate the restricted model parameters.Evaluate the score and covariance estimator at the restricted model estimates.
Pass the evaluated score, restricted covariance estimate, and the number of restrictions (i.e., the degrees of freedom) into
lmtest
.
If you find estimating parameters in the unrestricted model difficult, then use
lmtest
. By comparison:waldtest
only requires unrestricted parameter estimates.lratiotest
requires both unrestricted and restricted parameter estimates.
Algorithms
lmtest
performs multiple, independent tests when inputs are cell arrays.If the gradients and covariance estimates are the same for all tests, but the restricted parameter estimates vary, then
lmtest
“tests down” against multiple restricted models.If the gradients and covariance estimates vary, but the restricted parameter estimates do not, then
lmtest
“tests up” against multiple unrestricted models.Otherwise,
lmtest
compares model specifications pair-wise.
alpha
is nominal in that it specifies a rejection probability in the asymptotic distribution. The actual rejection probability can differ from the nominal significance. Lagrange multiplier tests tend to under-reject for small values ofalpha
, and over-reject for large values ofalpha
.Lagrange multiplier tests typically yield lower rejection errors than likelihood ratio and Wald tests.
References
[1] Davidson, R. and J. G. MacKinnon. Econometric Theory and Methods. Oxford, UK: Oxford University Press, 2004.
[2] Godfrey, L. G. Misspecification Tests in Econometrics. Cambridge, UK: Cambridge University Press, 1997.
[3] Greene, W. H. Econometric Analysis. 6th ed. Upper Saddle River, NJ: Pearson Prentice Hall, 2008.
[4] Hamilton, J. D. Time Series Analysis. Princeton, NJ: Princeton University Press, 1994.
Version History
Introduced in R2009a