# Lagrange multiplier test

(Redirected from Score test)

In statistics, the Lagrange multiplier (LM) test, also known as the score test, is one of three classical approaches to hypothesis testing, together with the Wald test and the likelihood-ratio test, for testing a null hypothesis ${\displaystyle H_{0}:\mathbf {c} (\theta )=\mathbf {0} }$ for a parameter of interest ${\displaystyle \theta }$.[1]

The basic idea behind the LM test is that if the restricted estimator[definition needed] is near the maximum of the likelihood function, the gradient of the likelihood function—known as the score function—evaluated at the restricted estimator should be close to zero, and can be shown to asymptotically follow a normal distribution with mean zero and known variance. This result has first been proved by C. R. Rao in 1948[2], leading to the original name of score test.

An alternative and numerically identical version of the test was derived by S. D. Silvey in 1959 using the vector of Lagrange multipliers in the Lagrangian expression of the constrained likelihood function,[3] which led to the name that has become more commonly used, particularly in econometrics, since Breusch and Pagan's much-cited 1980 paper.[1] If the constraint is non-binding at the maximum likelihood, the vector of Lagrange multipliers should be zero.

The main advantage of the LM test over the Wald test and likelihood ratio test is that the LM test only requires the computation of the restricted estimator. This makes testing feasible when the unconstrained maximum likelihood estimate is a boundary point in the parameter space.[citation needed] Further, because the LM test only requires the estimation of the likelihood function under the null hypothesis, it is less specific than the other two tests about the precise nature of the alternative hypothesis.[4]

## Single parameter test

### The statistic

Let ${\displaystyle L}$ be the likelihood function which depends on a univariate parameter ${\displaystyle \theta }$ and let ${\displaystyle x}$ be the data. The score ${\displaystyle U(\theta )}$ is defined as

${\displaystyle U(\theta )={\frac {\partial \log L(\theta \mid x)}{\partial \theta }}.}$
${\displaystyle I(\theta )=-\operatorname {E} \left[\left.{\frac {\partial ^{2}}{\partial \theta ^{2}}}\log L(X;\theta )\right|\theta \right]\,.}$

The statistic to test ${\displaystyle {\mathcal {H}}_{0}:\theta =\theta _{0}}$ is ${\displaystyle S(\theta _{0})={\frac {U(\theta _{0})^{2}}{I(\theta _{0})}}}$

which has an asymptotic distribution of ${\displaystyle \chi _{1}^{2}}$, when ${\displaystyle {\mathcal {H}}_{0}}$ is true. While asymptotically identical, calculating the LM statistic using the outer-gradient-product estimator of the Fisher information matrix can lead to bias in small samples.[6]

#### Note on notation

Note that some texts use an alternative notation, in which the statistic ${\displaystyle S^{*}(\theta )={\sqrt {S(\theta )}}}$ is tested against a normal distribution. This approach is equivalent and gives identical results.

### As most powerful test for small deviations

${\displaystyle \left({\frac {\partial \log L(\theta \mid x)}{\partial \theta }}\right)_{\theta =\theta _{0}}\geq C}$

where ${\displaystyle L}$ is the likelihood function, ${\displaystyle \theta _{0}}$ is the value of the parameter of interest under the null hypothesis, and ${\displaystyle C}$ is a constant set depending on the size of the test desired (i.e. the probability of rejecting ${\displaystyle H_{0}}$ if ${\displaystyle H_{0}}$ is true; see Type I error).

The score test is the most powerful test for small deviations from ${\displaystyle H_{0}}$. To see this, consider testing ${\displaystyle \theta =\theta _{0}}$ versus ${\displaystyle \theta =\theta _{0}+h}$. By the Neyman–Pearson lemma, the most powerful test has the form

${\displaystyle {\frac {L(\theta _{0}+h\mid x)}{L(\theta _{0}\mid x)}}\geq K;}$

Taking the log of both sides yields

${\displaystyle \log L(\theta _{0}+h\mid x)-\log L(\theta _{0}\mid x)\geq \log K.}$

The score test follows making the substitution (by Taylor series expansion)

${\displaystyle \log L(\theta _{0}+h\mid x)\approx \log L(\theta _{0}\mid x)+h\times \left({\frac {\partial \log L(\theta \mid x)}{\partial \theta }}\right)_{\theta =\theta _{0}}}$

and identifying the ${\displaystyle C}$ above with ${\displaystyle \log(K)}$.

### Relationship with other hypothesis tests

The likelihood ratio test, the Wald test, and the Score test are asymptotically equivalent tests of hypotheses.[7][8] When testing nested models, the statistics for each test converge to a Chi-squared distribution with degrees of freedom equal to the difference in degrees of freedom in the two models.

## Multiple parameters

A more general score test can be derived when there is more than one parameter. Suppose that ${\displaystyle {\widehat {\theta }}_{0}}$ is the maximum likelihood estimate of ${\displaystyle \theta }$ under the null hypothesis ${\displaystyle H_{0}}$ while ${\displaystyle U}$ and ${\displaystyle I}$ are respectively, the score and the Fisher information matrices under the alternative hypothesis. Then

${\displaystyle U^{T}({\widehat {\theta }}_{0})I^{-1}({\widehat {\theta }}_{0})U({\widehat {\theta }}_{0})\sim \chi _{k}^{2}}$

asymptotically under ${\displaystyle H_{0}}$, where ${\displaystyle k}$ is the number of constraints imposed by the null hypothesis and

${\displaystyle U({\widehat {\theta }}_{0})={\frac {\partial \log L({\widehat {\theta }}_{0}\mid x)}{\partial \theta }}}$

and

${\displaystyle I({\widehat {\theta }}_{0})=-\operatorname {E} \left({\frac {\partial ^{2}\log L({\widehat {\theta }}_{0}\mid x)}{\partial \theta \,\partial \theta '}}\right).}$

This can be used to test ${\displaystyle H_{0}}$.

## Special cases

In many situations, the score statistic reduces to another commonly used statistic.[9]

In linear regression, the Lagrange multiplier test can be expressed as a function of the F-test.[10]

When the data follows a normal distribution, the score statistic is the same as the t statistic.[clarification needed]

When the data consists of binary observations, the score statistic is the same as the chi-squared statistic in the Pearson's chi-squared test.

When the data consists of failure time data in two groups, the score statistic for the Cox partial likelihood is the same as the log-rank statistic in the log-rank test. Hence the log-rank test for difference in survival between two groups is most powerful when the proportional hazards assumption holds.

## References

1. ^ a b Breusch, T. S.; Pagan, A. R. (1980). "The Lagrange Multiplier Test and its Applications to Model Specification in Econometrics". Review of Economic Studies. 47 (1): 239–253. JSTOR 2297111.
2. ^ Rao, C. Radhakrishna (1948). "Large sample tests of statistical hypotheses concerning several parameters with applications to problems of estimation". Mathematical Proceedings of the Cambridge Philosophical Society. 44 (1): 50–57. doi:10.1017/S0305004100023987.
3. ^ Silvey, S. D. (1959). "The Lagrangian Multiplier Test". Annals of Mathematical Statistics. 30 (2): 389–407. JSTOR 2237089.
4. ^ Kennedy, Peter (1998). A Guide to Econometrics (Fourth ed.). Cambridge: MIT Press. p. 68. ISBN 0-262-11235-3.
5. ^ Lehmann and Casella, eq. (2.5.16).
6. ^ Davidson, Russel; MacKinnon, James G. (1983). "Small sample properties of alternative forms of the Lagrange Multiplier test". Economics Letters. 12 (3–4): 269–275. doi:10.1016/0165-1765(83)90048-4.
7. ^ Engle, Robert F. (1983). "Wald, Likelihood Ratio, and Lagrange Multiplier Tests in Econometrics". In Intriligator, M. D.; Griliches, Z. (eds.). Handbook of Econometrics. II. Elsevier. pp. 796–801. ISBN 978-0-444-86185-6.
8. ^ Burzykowski, Andrzej Gałecki, Tomasz (2013). Linear mixed-effects models using R : a step-by-step approach. New York, NY: Springer. ISBN 1461438993.
9. ^ Cook, T. D.; DeMets, D. L., eds. (2007). Introduction to Statistical Methods for Clinical Trials. Chapman and Hall. pp. 296–297. ISBN 1-58488-027-9.
10. ^ Vandaele, Walter (1981). "Wald, likelihood ratio, and Lagrange multiplier tests as an F test". Economics Letters. 8 (4): 361–365. doi:10.1016/0165-1765(81)90026-4.