Calculates sigma_2 forecasts based on the EGARCH model.

The formula is as follows:

\[\text{ln}\; \sigma_{} (n + h) ^{2} = L + \text{Beta} ^{h - 1} \cdot (\text{ln}\; \sigma_{} (n + 1) ^{2} - L)\] \[L = \text{Omega} / (1 - \text{Beta})\] \[\sigma_{n + h} ^{2} = \exp(\text{ln}\; \sigma_{} (n + h) ^{2})\]

Where n is the last observation, h = 1, …, time_steps (10 by default) the forecast step and sigma_(n+1)^2 the one-step-ahead variance of the fitted EGARCH(1, 1) recursion (see get_egarch). The shock terms drop out at their expectation of zero, so the forecast is the exponential of the expected log variance.

For more information about the method, see the following paper:

  • Nelson, D.B. (1991). “Conditional Heteroskedasticity in Asset

Returns: A New Approach.” Econometrica, 59(2), 347-370.

Also known as: volatility forecast, predicted volatility.

EGARCH Volatility Forecast in Python

Install the Finance Toolkit with:

pip install financetoolkit -U

Then call get_egarch_forecast as shown below.

from financetoolkit import Toolkit

toolkit = Toolkit(
    ["AMZN", "TSLA"],
    api_key="FINANCIAL_MODELING_PREP_KEY",
    start_date="2021-01-01",
    end_date="2025-12-31",
)

toolkit.risk.get_egarch_forecast(period="quarterly")

Which returns:

  AMZN TSLA Benchmark
2026Q1 0.0012 0.0028 0.0034
2026Q2 0.001 0.0026 0.0055
2026Q3 0.0009 0.0024 0.007
2026Q4 0.0008 0.0022 0.0079
2027Q1 0.0007 0.002 0.0084
2027Q2 0.0006 0.0018 0.0086
2027Q3 0.0005 0.0017 0.0087
2027Q4 0.0004 0.0016 0.0088
2028Q1 0.0004 0.0014 0.0089
2028Q2 0.0003 0.0013 0.0089

Parameters

get_egarch_forecast accepts the following parameters.

ParameterTypeDescriptionExample
periodstrThe data frequency for returns (daily, weekly, monthly, quarterly, or yearly). Defaults to “daily”."weekly"
time_stepsintTime steps to calculate EGARCH and to forecast sigma_2 values for. Defaults to 10.20
within_periodboolWhether to calculate EGARCH within each specified period or all at once. Defaults to False.True
roundingint | NoneThe number of decimals to round the results to. Defaults to None.2
growthboolWhether to calculate the growth of the EGARCH values over time. Defaults to False.True
lagint | list[int]The lag to use for the growth calculation. Defaults to 1.4
standardizeboolWhether to standardize (Z-Score) the result. When combined with growth=True, standardizes the growth values instead of the raw values. Defaults to False.True
Share