arch.univariate.base.ARCHModelResult.arch_lm_test

ARCHModelResult.arch_lm_test(lags: int | None = None, standardized: bool = False) → WaldTestStatistic

Perform an ARCH LM test for conditional heteroskedasticity.

Parameters:
lags: int | None = None

Number of lags to include in the model. Must be a positive integer (a Python or NumPy integer; floats and Booleans are rejected). If not specified, uses $lceil 12 (T/100)^{1/4} rceil$, where T is the number of non-missing residuals. In all cases the number of lags is limited to $lfloor T/2 rfloor - 1$.

standardized: bool = False

Flag indicating to test the model residuals divided by their conditional standard deviations. If False, directly tests the estimated residuals.

Returns:

result – Result of ARCH-LM test.

Return type:

arch.utility.testing.WaldTestStatistic

Raises:
  • TypeError – If lags is not an integer or standardized is not a bool.

  • ValueError – If lags is less than 1 or there are fewer than 3 non-missing residuals.

Notes

The test statistic is \(T R^2\), where \(R^2\) is the coefficient of determination from the auxiliary regression of the squared residuals on a constant and their own lags, and \(T\) is the total number of non-missing residuals. The regression uses the \(T - \text{lags}\) observations for which all lags are available, so the statistic is \(T/(T-\text{lags})\) times the statistic that scales \(R^2\) by the number of observations in the regression, as in statsmodels.stats.diagnostic.het_arch(). The statistic has an asymptotic \(\chi^2_{\text{lags}}\) distribution under the null.