EconBase
← Back to paper

HARd to Beat: The Overlooked Impact of Rolling Windows in the Era of Machine Learning

Extracted main text — title through conclusion, appendix excluded. This is what our citation measures are computed over, published so the extraction can be checked by eye.

55,654 characters · 18 sections · 76 citation commands

Rendered from LaTeX for readability, not typeset faithfully. Citation keys are highlighted; maths is left as source; figures, tables and equation environments are summarised rather than reproduced; unrecognised commands are greyed out so nothing is silently dropped. Email addresses are removed.

HARd to Beat: The Overlooked Impact of Rolling Windows in the Era of Machine Learning

frontmatter\address[sg]{University of St.Gallen, Switzerland} \cortext[cor]{Corresponding author} \ead{[email removed]} \begin{abstract} We investigate the predictive abilities of the heterogeneous autoregressive (HAR) model compared to machine learning (ML) techniques across an unprecedented dataset of {1{,}445} stocks. Our analysis focuses on the role of fitting schemes, particularly the training window and re-estimation frequency, in determining the HAR model's performance. Despite extensive hyperparameter tuning, ML models fail to surpass the linear benchmark set by HAR when utilizing a refined fitting approach for the latter. Moreover, the simplicity of HAR allows for an interpretable model with drastically lower computational costs. We assess performance using QLIKE, MSE, and realized utility metrics, finding that HAR consistently outperforms its ML counterparts when both rely solely on realized volatility and VIX as predictors. Our results underscore the importance of a correctly specified fitting scheme. They suggest that properly fitted HAR models provide superior forecasting accuracy, establishing robust guidelines for their practical application and use as a benchmark. This study not only reaffirms the efficacy of the HAR model but also provides a critical perspective on the practical limitations of ML approaches in realized volatility forecasting. \end{abstract} \begin{keyword} Forecasting practice, HAR, Machine learning, Realized volatility, Volatility forecasting \end{keyword}

Introduction

Accurate forecasts of realized volatility are essential for various financial applications, including risk management, derivative pricing, and portfolio optimization. The modeling of financial volatility has a deep-rooted history in academic literature and has undergone extensive exploration in recent decades Bauwens2012,Takahashi2023.

One simple model that stands out for its popularity and efficacy in realized volatility forecasting is the heterogeneous autoregressive (HAR) model, introduced by Corsi2009. This model predicts the next day's realized volatility by calculating a weighted average based on the realized volatilities of the preceding day, week, and month. Despite its simplicity, the HAR model has established itself as a widely adopted benchmark in the field, consistently demonstrating strong forecasting accuracy and often outperforming more complex models.

The rise of machine learning (ML) techniques over the past years has marked a paradigm shift in financial econometrics, offering a new set of tools to tackle the challenges of volatility prediction. This trend is supported by a growing body of literature, including studies by Audrino2016,Audrino2020,Bucci2020,Christensen2023,Zhang2023,Zhu2023, among others, which highlight the diverse applications and potential benefits of ML in this area.

Given financial data's complex and often nonlinear nature, ML appears well-suited to uncover complex patterns that may elude traditional linear models such as the HAR model. This intuition is supported by empirical evidence, which suggests that ML methods can indeed improve upon the forecasting accuracy of the HAR model Gunnarsson2024.

In this study, we argue that the reality is more subtle and, despite their appeal, ML methods are not a panacea for volatility forecasting. Specifically, our findings demonstrate that the effectiveness of the HAR model is highly sensitive to the choice of fitting scheme. HAR models are typically estimated in a rolling window fashion, where the model is re-estimated at regular intervals using a fixed (or increasing) number of past observations. As such, a researcher must specify two key parameters when estimating the HAR model: the training window size and the re-estimation frequency. As Figure (ref) illustrates, the specification of these parameters profoundly impacts the model's forecasting accuracy. This study shows that the optimal fitting schemes are exceptionally hard to beat, even when using sophisticated ML techniques. The most notable feature of this figure is the substantial deterioration of the forecasting performance when the model is not re-estimated daily, even when the re-estimation frequency is relatively high, e.g., every two or five days. While the impact of the training window size is less pronounced than that of the re-estimation frequency, the bottom half of Figure (ref) shows that this parameter also plays a crucial role in obtaining accurate forecasts. In particular, larger training windows generally lead to lower prediction errors, with the optimal window size being roughly two and a half to four years. Naturally, a higher re-estimation frequency and larger training windows leads to higher computation costs. However, this computational burden is greatly alleviated by the simplicity and linearity of the HAR model, which allows for efficient estimation even with large datasets.

figure[figure omitted — 916 chars of source]

Related Literature

Realized volatility forecasts have been the subject of extensive research in finance, and numerous econometric models have been proposed over the years Bauwens2012. In recent years, ML techniques have gained popularity in financial econometrics, offering a new set of tools to tackle the challenges of volatility prediction. Gunnarsson2024 provide an extensive modern survey of volatility forecasts with ML. Our work focuses on literature that applies ML techniques to RV forecasts, specifically emphasizing studies that use the HAR model as a benchmark. We summarize the key findings of these studies below and provide an overview of the different fitting schemes these studies use for the baseline HAR model in Table (ref).

Audrino2016 apply the least absolute shrinkage and selection operator (lasso) to the task of RV forecasting. They show that if HAR is the true data-generating process, lasso can recover the lag structure of the HAR model asymptotically. Empirically, they find that the lasso and the HAR model suggest a different lag structure, and the two models perform similarly in terms of out-of-sample forecasting accuracy. Audrino2020 also apply the lasso methodology to RV forecasting. However, they go beyond adding simple lags and extend the baseline model with covariates derived from economic variables and investor attention and sentiment measures. Their findings suggest that including these additional features can improve forecast accuracy compared to the HAR model. Liu2018 propose RV forecasts using recurrent neural networks (RNNs). They find evidence suggesting that RNNs can improve forecast accuracy when the training sample is small. However, as the training sample size increases, the HAR model outperforms the RNNs. Qiu2021 proposes an ML model based on support vector regression and finds that it outperforms the HAR model in an out-of-sample forecasting exercise on Bitcoin data. Zhang2023 compare the HAR model with a wide range of ML models, including lasso, random forests (RFs), gradient-boosted trees (GBTs), feedforward neural networks (FFNNs), and long short-term memory networks (LSTMs). They consider several training specifications, including individual stock estimation and pooled estimation. They find that augmenting the features with intraday data can improve forecast accuracy when using ML models, particularly FFNNs. Christensen2023 compare an extensive collection of ML models with various HAR model specifications, first using the information set of the original HAR model and then augmenting it with firm characteristics and macroeconomic variables, where the richer information set may allow ML models to demonstrate superior performance. While they use a rolling window scheme for the HAR model, they do not mention the exact training window and stride length used. Thus, we cannot report this information in Figure (ref) or Table (ref).

Notably, when considering Figure (ref) and Table (ref) in conjunction with the findings of the studies summarized above, we observe that studies with a daily re-estimation and long training windows tend to find that the HAR model is competitive with or outperforms ML models. In contrast, studies with suboptimal fitting schemes for the HAR model tend to find that ML models outperform the HAR model. As we demonstrate in this study, these discrepancies can easily be explained by the sensitivity of the HAR model's performance to the choice of fitting scheme, i.e., training window length and re-estimation frequency.

table[table omitted — 774 chars of source]

Lastly, our study does not extend the information set beyond the past RV series and the volatility index (VIX), the latter being a typical and cost-effective addition for improving the forecast accuracy of HAR models Audrino2020,Buncic2016,Zhang2020. While other studies, such as Audrino2020,Christensen2023, demonstrate that extending the information set can improve forecasts, our research concentrates on optimizing the predictive power of the HAR model using a narrow and well-established information set that any practitioner can easily implement. This focus allows us to assess the intrinsic forecasting power of the HAR model and the extent to which ML models can improve upon it, leaving the exploration of richer information sets for future research.

Data

Realized Volatility

We consider a financial asset whose price evolves following a stochastic model represented by $$dp(t) = \mu(t) dt + \sigma(t) dW(t),$$ in which $p(t)$ denotes the logarithm of the price at any given time $t$, $\mu(t)$ embodies the trend or drift, $\sigma(t)$ is the level of volatility, and $W(t)$ models a standard Brownian motion. Within this framework, a theoretical concept for measuring volatility over a specific period $(t-h, t]$ emerges as the integrated variance (IV), mathematically expressed as $$\mathrm{IV}(t, h) = \int_{t-h}^{t} \sigma^2(s) ds,$$ where $h$ represents the duration or lookback period. However, the theoretical construct of IV is not directly observable in real-world scenarios, necessitating estimations. The concept of realized volatility (RV), introduced through foundational contributions by Andersen2001,Andersen2003,Barndorff-Nielsen2002,Barndorff-Nielsen2002a has become a widely adopted metric for estimating the IV in practice. This measure leverages high-frequency intraday data to provide a consistent estimator of the IV. In line with previous research Andersen2003,Zhang2023, we adopt the logarithmic RV estimator, which is well-known to outperform its standard counterpart Clements2021,Taylor2017. We define the one-day logarithmic RV as

equation[equation omitted — 103 chars of source]

where $r_{t- \Delta i }$ denotes the intraday logarithmic return over $\Delta$ minutes, and $m$ represents the number of intervals in a trading day\footnote{While the primary focus of this study is on the fitting schemes and performance of the HAR model, it is important to note that our analysis does not specifically address the complications arising from jumps or microstructure noise in the financial data. When such factors are present, our approach estimates the total IV contributions, including jumps.}. In particular, we set $\Delta = 5$, corresponding to an interval widely used in the literature and shown to be difficult to outperform Liu2015.

Intraday Data

In our analysis, we conduct a thorough examination of stocks traded on U.S. exchanges. Specifically, we focus on the constituents of the Center for Research in Security Prices' (CRSP) U.S. Stock Database, for which we can obtain matching ticker symbols in the New York Stock Exchange (NYSE) Trade and Quote (TAQ) database. We source high-frequency intraday trade data for all selected stocks from the TAQ database from January 1, 2015, to October 31, 2023. These data are processed following the methodology suggested by Barndorff-Nielsen2009.

We query high-frequency data for a total of {6{,}061} stocks. Among these, {1{,}445} stocks remain consistently present throughout the nine years. Out of these {1{,}445} stocks, {27} belong to the DJIA index (out of the 30 total constituents), and {69} are part of the Nasdaq-100 index (out of the 100 total constituents). Our study focuses on the entire set of {1{,}445} stocks to provide a comprehensive and unprecedented analysis of the performance of the models across a broad spectrum of the market. However, we also perform an additional analysis of the DJIA and Nasdaq-100 stocks in the appendix to validate our main results further. These specific subsets of stocks are selected for their economic significance and increased liquidity and trading activity compared to the entire range of stocks, making the results obtained in the appendix potentially more relevant to practical applications. In so doing, we aim to demonstrate that our main findings hold even in these more focused and economically relevant universes, which are more often studied in financial literature. Thus, we reinforce the applicability and robustness of our results. This starkly contrasts our work with previous research, which typically focuses on a rather limited number of stocks (see Table (ref)).

Methodology

Heterogeneous Autoregressive Model

The HAR model, introduced by Corsi2009, provides a parsimonious and economically interpretable linear model for RV forecasting that is straightforward to implement and offers a high degree of flexibility and adaptability, as evidenced by several extensions and modifications proposed in the literature Corsi2012.

In its canonical formulation, the HAR model is expressed as

equation[equation omitted — 200 chars of source]

where $\mathrm{RV}_{i,t}^{(d)}$ denotes the logarithm of the daily realized volatility (ref) of stock $i$ at time $t$, $\mathrm{RV}_{i,t}^{(w)} = \frac{1}{5}\sum_{h=1}^5 \mathrm{RV}_{i,t-h+1}^{(d)}$ and $\mathrm{RV}_{i,t}^{(m)} = \frac{1}{22}\sum_{h=1}^{22} \mathrm{RV}_{i,t-h+1}^{(d)}$ represent the weekly and monthly realized volatilities, respectively, and $\{\varepsilon_{i,t}\}_{t\in\mathbb{Z}}$ is a zero-mean innovation process.

An especially compelling feature of the HAR model is its linearity, allowing for the effortless incorporation of additional predictors at a low computational cost. In particular, the Chicago Board Options Exchange (CBOE) Volatility Index (VIX) has been demonstrated to markedly improve the model's predictive capability when included as an additional predictor Audrino2020,Buncic2016,Zhang2020. The VIX measures the stock market's expectation of future volatility. It is calculated using the implied volatilities of a wide range of S&P 500 index options and thus provides additional market-wide information not captured by an individual stock's realized volatility. The resulting model is referred to as HAR-VIX and is expressed as

equation[equation omitted — 235 chars of source]

where $\mathrm{VIX}_{t}$ denotes the VIX at time $t$.

The HAR and HAR-VIX models are typically estimated using ordinary least squares (OLS) regression per stock. However, Clements2021 suggest that alternative estimation techniques, such as weighted least squares (WLS) and robust regression, can significantly enhance forecast accuracy. Furthermore, pooled approaches have garnered attention, wherein the HAR model is simultaneously estimated across various stocks. This method capitalizes on the entire dataset to enhance forecast accuracy, as suggested by Patton2015,Zhang2023,Bollerslev2018.

To conduct a comprehensive comparison between the HAR and HAR-VIX models and their machine learning counterparts, we estimate equations (ref) and (ref) using both OLS and WLS regression methods. These estimations are performed individually for each stock and in a pooled manner, resulting in eight distinct specifications. The HAR models are estimated using a rolling window approach described in Section (ref).

Machine Learning Models

Least Absolute Shrinkage and Selection Operator

The Least Absolute Shrinkage and Selection Operator (lasso) introduced by Tibshirani1996 is a linear regression method that applies a penalty on the absolute values of the regression coefficients. This penalty shrinks the coefficients of less important predictors to zero, effectively performing variable selection. Lasso is especially attractive in high-dimensional settings, offering models that are both interpretable and predictively proficient Hastie2015,Hastie2009. Consequently, the lasso emerges as an appealing ML candidate for RV forecasting, with the potential to provide an economically tractable model. Audrino2016,Audrino2020,Zhang2023,Christensen2023 have previously applied the lasso to the problem of RV forecasting. Lasso modifies the standard linear regression model by solving the following optimization problem:

equation[equation omitted — 250 chars of source]

where $\mathbf{y}$ is the vector of outcomes, $\mathbf{X}$ is the design matrix, $\boldsymbol{\beta}$ is the vector of regression coefficients, and $\lambda$ is a penalty parameter that controls the amount of shrinkage applied to the coefficients.

Random Forest

The Random Forest (RF) algorithm, proposed by Breiman2001, is a popular ensemble learning method that constructs numerous decision trees and aggregates their predictions to enhance predictive accuracy and control overfitting. RFs operate as bagging algorithms, as described by Breiman1996; i.e., they leverage bootstrap sampling to create multiple predictors. This technique reduces variance by averaging the predictions from various low-bias, high-variance models, enhancing the model's generalization error.

For a comprehensive understanding of RF, readers are directed to seminal works by Breiman2001 and Hastie2009. Here, we only provide a concise summary of the RF construction process:

enumerate\setlength\itemsep{0em} • Bootstrap Sampling: Draw a bootstrap sample from the original dataset. • Tree Construction: Individually grow each tree by randomly selecting a subset of features at each decision split, effectively de-correlating the trees. • Forest Creation: Repeat the first two steps to generate many trees, forming a forest.

The final model prediction is derived by averaging the predicted outcomes across all the trees, thereby mitigating any individual tree's prediction errors.

In the context of RV forecasting, Luong2018 have found RFs to outperform the performance of the traditional HAR model. These results are somewhat mitigated by Christensen2023, who find that RFs only outperform the HAR model when the information set is expanded to include firm characteristics and macroeconomic variables as additional features. However, Christensen2023 do not perform any hyperparameter tuning for their RF model, which may negatively impact its performance. Moreover, when the information set of the HAR model is expanded to include the same features as the RF model, the performance discrepancy is no longer statistically significant.

Gradient Boosted Trees

Gradient Boosted Trees (GBTs), introduced by Friedman2001, is another powerful ensemble learning technique that sequentially builds decision trees, unlike RFs, which construct trees independently. Each tree in a GBT model is constructed to correct the residual errors of previous trees, thereby enhancing the model's predictive power with each iteration.

An in-depth discussion of GBTs is provided in the original paper by Friedman2001 and the comprehensive work of Hastie2009. We restrict our discussion to a brief overview of the GBT construction process:

enumerate\setlength\itemsep{0em} • Initialize a Base Model: Start with a simple predictive model (e.g., constant prediction of the mean). • Sequential Tree Building: For each subsequent tree, focus on correcting the errors made by previous trees. This is achieved by fitting a new tree to the residuals of the current model. • Combine Predictors: Aggregate the predictions from all individual trees using a weighted sum to obtain the final model prediction, where the learning rate determines the weights. This hyperparameter controls the contribution of each tree.

In the context of RV forecasting, Zhang2023 do not find gradient boosting to outperform the HAR model or other ML models. Similarly, Christensen2023 find that GBTs do not outperform the HAR model when the information set is limited to RV series. On the other hand, if the information set is expanded to include firm characteristics and macroeconomic variables, they find that GBTs outperform the HAR model. However, as with the RF model, the HAR model's performance is not statistically different from the GBT model when the information set is expanded to include the same features as the GBT model.

Feedforward Neural Network

Feedforward Neural Networks (FFNNs), often referred to as Multilayer Perceptrons (MLPs), is a foundational class of artificial neural networks composed of multiple layers of neurons, with each neuron in a layer connected to all neurons in the subsequent layer via weighted connections. A typical FFNN consists of an input layer, one or more hidden layers, and an output layer.

The primary appeal of FFNNs lies in their ability to approximate virtually any function, given a sufficient number of neurons and layers Hornik1991. This ability makes them highly versatile and well-suited for capturing complex patterns in high-dimensional data; as such, FFNNs have become a standard tool in the ML toolkit. Several textbook references provide a comprehensive overview of FFNNs, including Goodfellow2016 and Hastie2009.

Regarding realized volatility, Zhang2023 find that FFNNs outperform the HAR model for intraday RV forecasting. However, these results do not hold when it comes to daily volatility, for which the HAR model is designed. On the other hand, Christensen2023 find that several FFNN architectures outperform the HAR model even when the information set is limited to be the same as what the HAR model uses.

Estimation Strategy

One of the most notable strengths of ML techniques is their ability to process high-dimensional data, which facilitates the inclusion of diverse covariates beyond the handcrafted features of the HAR models. As discussed in Section (ref), this study deliberately focuses on the plain HAR model setting without extending the information set to include predictors outside the RV series and the VIX. Nonetheless, we augment the information set by incorporating 100 lags of the RV series, allowing the ML models to potentially capture long-term dependencies in the data that may elude the HAR models. Enlarging the information set by including additional features, such as sentiment indicators in the spirit of Audrino2020 or firm characteristics as in Christensen2023, is left for future research.

ML approaches often require fine-tuning hyperparameters, and the particular choice of hyperparameters significantly impacts the model's predictive performance. The methods outlined in Section (ref) are no exception to this rule. However, the computational burden of hyperparameter optimization presents a substantial obstacle for the rolling re-estimation of ML models. Therefore, implementing a rolling window methodology with an extensive training period and minimal re-estimation frequency proves impractical for analyzing a wide array of assets. Table (ref) summarizes the fitting times for the HAR and ML models for a single stock. The rolling window approach used for the HAR models necessitates re-estimating the model for each observation in the test set, resulting in a total of 460 re-estimations. In contrast, the fitting times for the ML models represent the average time required using a static training window and hyperparameter tuning on the validation set. Estimating the ML models using a rolling window approach would require repeating this process for each new observation in the test set, resulting in a substantial increase in computational time (roughly 460 times longer than the static training window approach). The goal of Table (ref) is not to provide a detailed comparison of the computational efficiency of the models but to illustrate the computational challenges associated with the rolling window approach for ML models. Moreover, the table highlights the runtime differences for our selection of hyperparameter candidates, which are driven by the fitting times of the models (i.e., we choose the optimal $\lambda$ for the lasso model using $1{,}000$ candidates as it is an ML model with a relatively short fitting time, while we use only $27$ candidates for the RF model, which results in a relatively shorter fitting time).

table[table omitted — 968 chars of source]

Recent studies exploring multiple ML models for RV prediction across numerous stocks have adopted different strategies to address this computational challenge. For instance, Christensen2023 tackle this issue by employing a static training window, dividing the dataset into 70% training, 10% validation, and 20% test data. Conversely, Zhang2023 opt for an expanding window method with an extended stride length, updating their models only every 250 days. Notably, both studies find that ML models outperform the HAR model regarding forecast accuracy. However, Zhang2023 benchmark their models against the HAR model with the same 250-day stride length, severely hampering the HAR model's performance without a substantial gain in computational efficiency for this simple linear model. This approach is particularly disadvantageous for the HAR model, as the model's performance is highly sensitive to the choice of the re-estimation window, as illustrated in Figure (ref).\footnote{While Christensen2023 also use a rolling window for the HAR model, we cannot make an exact statement about the fitting scheme used, as they do not provide a detailed description of their training window and stride length for the HAR models.} While Figure (ref) illustrates the sensitivity of the HAR model's performance to the re-estimation frequency and training window size, it does so for HAR models estimated using a rolling window approach. In contrast, the HAR models in Zhang2023 are estimated using an expanding window method. We report the analogous heatmap for the expanding window method in the appendix in Figure (ref), which shows that the starting training window size has a smaller impact on the model's performance compared to the rolling window approach. However, the re-estimation frequency remains a crucial determinant of the model's forecasting accuracy, even when using an expanding window method.

Adopting a strategy akin to that of Christensen2023, we implement a static training window for our ML algorithms. Specifically, our dataset is divided into a training period from January 2016 to December 2020, a validation period from January 2021 to December 2021, and a test period from January 2022 to November 2023, resulting in approximate splits of 64%, 13%, and 23% for the training, validation, and testing sets, respectively. In contrast, we opt for a rolling window method with a training duration of 630 days (approximately three and a half years) and daily stride length for the HAR and HAR-VIX models. This choice is motivated by the findings in Figure (ref), indicating that the HAR model's performance is highly sensitive to the stride length. However, it remains relatively stable for training window lengths between two and four years when the stride length is set to one.

For each ML model, hyperparameter tuning is conducted individually for each stock on the validation set, using the candidate values outlined in (ref). While the set of assets we consider is far more extensive than used in any previous study, putting a further strain on computational resources required by the ML models, we ensure these candidates span a wide enough spectrum to provide comparable results to the hyperparameter choices studied in previous research Zhang2023,Christensen2023.\footnote{Note that Zhang2023 only report the chosen hyperparameter values, not the candidates. Hence, we can only ensure these final values are a subset of our candidates.} However, our primary aim is not to focus on exhaustive hyperparameter optimization but to demonstrate that out-of-the-box ML models do not effortlessly surpass a correctly fitted HAR or HAR-VIX baseline model, as previously suggested. We provide a detailed discussion of the hyperparameters considered for each model in (ref).

Evaluation Metrics

We evaluate the models' out-of-sample performance using the test set from January 2022 to November 2023. We report the aggregated results across all {1{,}445} stocks in the main text and provide additional insights into the performance of the models for the DJIA and Nasdaq-100 stocks in the appendix. Although the DJIA and Nasdaq-100 stocks are less representative of the entire market, they provide a more focused view of economically significant stocks, and the current literature on RV forecasting often focuses solely on constituents of such indices Audrino2020,Christensen2023,Zhang2023. This justifies the inclusion of these subsets in our analysis, as they allow for a more direct comparison with previous research. This ensures that our results are robust and not only driven by including less liquid or less economically significant stocks.

Statistical Loss Functions

To assess the models' predictive accuracy, we use two standard evaluation metrics from the literature, namely the MSE,

equation[equation omitted — 136 chars of source]

and the “QLIKE” loss function Patton2011,

equation[equation omitted — 257 chars of source]

where $T$ is the number of trading days in the test period, $\mathrm{RV}_{i,t}^{(d)}$ is the daily realized volatility of stock $i$ at time $t$, and $\widehat{\mathrm{RV}}_{i,t}^{(d)}$ is the model's forecast.

For each asset, we use the model confidence set (MCS) procedure Hansen2011 to compare the models' performance. The MCS is a statistical procedure that compares multiple models based on their out-of-sample loss. Due to its widespread use in the RV forecasting literature Audrino2020,Cipollini2021,Zhang2023,Christensen2023, we do not provide a detailed explanation of the MCS procedure here and refer the reader to the original paper by Hansen2011 for a comprehensive description. We conduct the MCS procedure at a 95% confidence level for each stock individually, using the MSE and QLIKE loss functions as the metrics of interest. Finally, we report the percentage of stocks for which each model is included in the collection of “best” models returned by the MCS procedure, providing a comprehensive overview of the models' performance across the entire set of stocks.

Economic Performance

While MSE and QLIKE metrics measure statistical loss performance, they lack a direct economic interpretation. To address this shortcoming, Bollerslev2018 introduce a utility-based framework to assess risk models more comprehensively. This framework evaluates risk models through the lens of the expected utility of an investor with mean-variance preferences trading an asset with a constant Sharpe ratio. Investors aim to maintain a constant level of volatility by adjusting their portfolio position based on the models' forecasts, thereby creating a direct link between the models' predictions and the investors' utility. We refer the reader to Bollerslev2018,Zhang2023 for a detailed explanation of the realized utility framework and note that the realized utility may be computed using the forecasts as

equation[equation omitted — 270 chars of source]

where $\mathrm{SR}$ is the Sharpe ratio, $\gamma$ is the risk aversion parameter, $\mathrm{RV}_{t+1}$ is the realized volatility, and $\widehat{\mathrm{RV}}_{t+1}$ is the model's forecast.

For the sake of comparison, we implement the realized utility framework using the same specifications as Bollerslev2018,Zhang2023, i.e., a risk aversion parameter of $\gamma = 2$ and a Sharpe ratio of 40%. By Equation (ref), this specification implies that a model with perfect predictions can achieve at most a realized utility of $\mathrm{SR}^2 / (2\gamma) = 4\%$. As Bollerslev2018 describe, realized utility may be interpreted as the percentage of wealth the investor is willing to pay to have access to the model's forecasts; i.e., an investor would be willing to give up 4% of their wealth to have access to the portfolio guided by a perfect model instead of investing entirely in the risk-free asset. We assess the realized utility for each model on a per-stock basis and report the average utility across all stocks to provide a broad overview of the models' economic performance. Moreover, we also conduct the realized utility analysis when transaction costs are considered. In this setting, we follow Bollerslev2018 and use the rolling median of the bid-ask spread over the last nine months as a proxy for transaction costs.

Results

This section reports the main findings for the full sample of {1{,}445} stocks. Additional tables focusing solely on DJIA and Nasdaq-100 constituents are provided in (ref) and (ref), respectively.

table[table omitted — 1,065 chars of source]

Table (ref) showcases the results of the MCS procedure using MSE and QLIKE as the loss functions, while Table (ref) and Table (ref) provide detailed statistics for each model and loss function. In particular, Table (ref) details the percentage of assets for which each model is considered to belong to the best model class with a 95% confidence level. A notable observation is the consistent improvement in model performance when incorporating the VIX as an additional predictor, except for the QLIKE of the HAR model estimated via WLS in a pooled manner. This performance gain is more pronounced in non-pooled models, aligning with the expectation that VIX, as a market-wide volatility measure, offers more value in models that do not already incorporate broad market trends through pooling. Interestingly, this finding might also suggest that the benefits of pooling, as documented in Bollerslev2018,Zhang2023, may diminish when the VIX is included in the model's information set. This relationship between VIX inclusion and model performance underscores the importance of market-wide information in volatility forecasting. It corroborates previous findings about adding the VIX in the literature Audrino2020,Buncic2016,Zhang2020. The divergence in performance between the MSE and QLIKE metrics is particularly pronounced in the HAR models, which are estimated via OLS. This discrepancy highlights the importance of selecting an appropriate estimation method for the HAR model, supporting the findings of Clements2021 and underscoring the potential pitfalls of using OLS to estimate the HAR model in situations where one aims to capture the asymmetries and tail risks that the QLIKE function is sensitive to.

table[table omitted — 1,903 chars of source]

A salient observation from our analysis is the relative underperformance of ML models compared to HAR models, especially when the latter are estimated using WLS. Although the lasso model stands out with competitive performance, other ML models consistently lag behind the HAR model estimated via WLS by a substantial margin, regardless of the performance metric used. This is further corroborated by the summary statistics in Tables (ref) and (ref). These findings contradict previous studies suggesting that ML models can outperform HAR models in volatility forecasting Zhang2023,Christensen2023,Qiu2021. As Figure (ref) illustrates and as we argue throughout this work, the choice of fitting scheme for the HAR model is a crucial determinant of its forecasting accuracy and a major reason for the discrepancy in results across studies. Moreover, the results we obtain for DJIA and Nasdaq-100 constituents in (ref) and (ref) are consistent with the findings for the full sample, and the underperformance of ML models is even more pronounced in these subsets.

table[table omitted — 1,907 chars of source]

Table (ref) and Table (ref) illustrate the economic relevance of the models through the financial perspective of realized utility as defined in Bollerslev2018, with and without considering transaction costs, respectively. In both scenarios, the HAR model estimated via WLS markedly outperforms the other models, regardless of whether VIX is included. As described in Bollerslev2018, the values may be interpreted as the percentage of wealth that an investor would be willing to pay in order to access a portfolio that leverages the model's forecasting capabilities compared to a portfolio that uniquely allocates capital in the risk-free asset. In turn, the difference in realized utilities between the various models can be interpreted as the wealth that an investor would be willing to pay to access the superior forecasting capabilities. For instance, when transactions are costly and the VIX is excluded, an investor using the lasso model would be willing to pay 8.7 basis points of their wealth as a fee to access the forecasts of the HAR model estimated via WLS. This consistent superiority in economic performance strengthens the findings obtained from the statistical losses and underscores the prevalence of the HAR model in volatility forecasting. Moreover, the results for realized utilities for DJIA and Nasdaq-100 constituents in (ref) and (ref) confirm the robustness of these findings within subsets of more actively traded and economically significant stocks.

table[table omitted — 2,089 chars of source]
table[table omitted — 2,104 chars of source]
figure[figure omitted — 462 chars of source]

Figure (ref) illustrates the cumulative squared error difference (CSED) for various models compared to the HAR-VIX model estimated via OLS, which provides the best performance in terms of average MSE across all assets. The figure highlights that the difference in performance between the models is not driven by specific time spans but is consistent across the entire testing period from early 2022 to late 2023. All HAR models benefit from the inclusion of the VIX in a consistent manner; i.e., throughout the entire time period, the CSED is lower when the VIX is included. This observation does not hold for the ML models, which all exhibit a similar pattern where the CSED when the VIX is included is lower at the beginning of the testing period but increases over time and eventually surpasses the value of the CSED when the VIX is not included. However, this pattern of performance deterioration over time is not observed in the restricted samples of DJIA and Nasdaq-100 constituents, as shown in in the appendices. In these subsets, the CSED indicates that the inclusion of the VIX consistently improves the performance.

Conclusion

Grounded on a substantial and unprecedented dataset of {1{,}445} stocks from the U.S. equity market, our empirical analysis demonstrates that a carefully fitted HAR model remains a particularly robust benchmark for realized volatility forecasting. Despite the growing popularity of ML techniques in financial econometrics and their usefulness in capturing complex nonlinear patterns, our results challenge the notion that these methods may be a universal solution for volatility prediction. The additional model complexity and associated computational burden of traditional ML algorithms may negatively impact forecasting performance, especially when the information set is limited.

In contrast, the HAR model's linear structure makes it a lightweight, interpretable, and robust forecasting tool, particularly when the fitting scheme is meticulously selected. Our results emphasize the necessity of carefully specifying the training window and re-estimation frequency, demonstrating that these critical specification choices significantly influence the HAR model's performance.

Even when tested across subsets of the DJIA and Nasdaq-100 constituents, our findings remain robust, reinforcing the HAR model's broad applicability and practical relevance in realized volatility forecasting.