statsmodels.stats.diagnostic.linear_lm¶
-
statsmodels.stats.diagnostic.linear_lm(resid, exog, func=
None
)[source]¶ Lagrange multiplier test for linearity against functional alternative
# TODO: Remove the restriction limitations: Assumes currently that the first column is integer. Currently it does not check whether the transformed variables contain NaNs, for example log of negative number.
Notes
Written to match Gretl’s linearity test. The test runs an auxiliary regression of the residuals on the combined original and transformed regressors. The Null hypothesis is that the linear specification is correct.
Last update:
Dec 23, 2024