I have the errors when learning GARCH: lags must be unique, positive integers?

조회 수: 2 (최근 30일)
Yufei Cao
Yufei Cao 2021년 2월 5일
답변: Asvin Kumar 2021년 2월 8일
I am not sure why I have this error when using name-value to define lags. Any ideas?

답변 (1개)

Asvin Kumar
Asvin Kumar 2021년 2월 8일
'GARCHLags' and 'ARCHLags' properties can only be positive vectors. See function syntax. This is because the 'GARCHLags' input corresponds to the lag of the 'GARCH' coefficients as is the case for 'ARCHLags'. Refer to this example:
g = garch('GARCHLags',[1 2 3],'GARCH', [0.06 0.07 0.08], 'ARCHLags',[1 2], 'ARCH', [0.09 0.10])
g =
garch with properties:
Description: "GARCH(3,2) Conditional Variance Model (Gaussian Distribution)"
Distribution: Name = "Gaussian"
P: 3
Q: 2
Constant: NaN
GARCH: {0.06 0.07 0.08} at lags [1 2 3]
ARCH: {0.09 0.1} at lags [1 2]
Offset: 0
You can read more about GARCH models at this link https://www.mathworks.com/help/econ/what-is-a-conditional-variance-model.html#btbsicl This gives a good explanation about the lags and the coefficients.
So why is garch(0,0) valid then?
It's valid because it creates a default GARCH model without any GARCH or ARCH coefficients. Refer example here.

카테고리

Help CenterFile Exchange에서 Conditional Variance Models에 대해 자세히 알아보기

태그

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by