arch icon indicating copy to clipboard operation
arch copied to clipboard

arch_lm_test fails when the AR mean model is used.

Open borderite opened this issue 3 years ago • 0 comments

The arch_lm_test method in the class arch.univariate.base.ARCHModelResult fails if the mean model uses the AR model (p>0). It seems to me that the problem comes from "nan" at the top of resid2, but I am not too sure.

import scipy as sp from arch import arch_model Y = sp.stats.distributions.norm.rvs(size=1000) model = arch_model(Y, mean="AR", lags=1, vol="GARCH", rescale=True) fit = model.fit() print(fit.arch_lm_test())

Thanks.

borderite avatar Aug 05 '22 22:08 borderite

Thanks.

bashtage avatar Aug 11 '22 11:08 bashtage