Forecasting (Jun 2024)

Machine Learning-Enhanced Pairs Trading

  • Eli Hadad,
  • Sohail Hodarkar,
  • Beakal Lemeneh,
  • Dennis Shasha

DOI
https://doi.org/10.3390/forecast6020024
Journal volume & issue
Vol. 6, no. 2
pp. 434 – 455

Abstract

Read online

Forecasting returns in financial markets is notoriously challenging due to the resemblance of price changes to white noise. In this paper, we propose novel methods to address this challenge. Employing high-frequency Brazilian stock market data at one-minute granularity over a full year, we apply various statistical and machine learning algorithms, including Bidirectional Long Short-Term Memory (BiLSTM) with attention, Transformers, N-BEATS, N-HiTS, Convolutional Neural Networks (CNNs), and Temporal Convolutional Networks (TCNs) to predict changes in the price ratio of closely related stock pairs. Our findings indicate that a combination of reversion and machine learning-based forecasting methods yields the highest profit-per-trade. Additionally, by allowing the model to abstain from trading when the predicted magnitude of change is small, profits per trade can be further increased. Our proposed forecasting approach, utilizing a blend of methods, demonstrates superior accuracy compared to individual methods for high-frequency data.

Keywords