s-broda / ARCHModels.jl

A Julia package for estimating ARMA-GARCH models.
https://juliaeconometrics.wordpress.com/
Other
90 stars 18 forks source link

add multi-step predictions for returns and VaR #83

Closed SebRollen closed 3 years ago

SebRollen commented 3 years ago

This PR adds in multi-step forecasts for what=:return and what=:VaR by using the one-period prediction for time t of return as the data for the t+1 prediction

s-broda commented 3 years ago

Thanks for this!

The fix for the mean forecast looks correct to me. However the error message for the VaR forecast was there on purpose: the distribution of the multi-period return is not the same as the error distribution, even if the errors are normal. Computing the true distribution is only possible via its characteristic function, which has a very complicated form even for a simple GARCH(1, 1). Thus, one would probably have to rely on simulation to get the quantiles. As long as that isn't implemented, I'd rather give an error than a wrong result.

Come to think of it, we should also disallow forecasting the variance of an EGARCH more than 1-period ahead. What it's doing now is forecasting log variance and then taking the exponential. Due to Jensen's inequality, that's not a correct forecast in the conditional expectation sense.

SebRollen commented 3 years ago

Hi, thanks for the explanation! That makes a lot of sense, I've updated the PR to only incorporate the updates for the mean forecast as that was really the issue I set out to fix in the first place

s-broda commented 3 years ago

Great, thanks! If CI clears this should be good to go, except that the docstring needs some tweaking.

Feel like tackling the multivariate case as well? Getting greedy, I know :)

SebRollen commented 3 years ago

Updated the docstring, open to suggestions on language! I might have some time to tackle the multivariate case in the next couple of weeks, but can't make any promises haha.

s-broda commented 3 years ago

Merged. Thanks for your contribution!

I'll tag a new release.