Skip main navigation

Recurrent Neural Network for time series data

Which type of neural network model is most effective for time series data? In this article, Dr Hao Ni introduces the motivation of RNNs.

As discussed in the previous step, time series data are ubiquitous in financial applications. In this article, we introduce a Recurrent Neural Network (RNN), which has strength for time series modelling by incorporating the sequential nature of data into network design.

Time series refers to the collection of data points indexed by time. More specifically, a (mathcal{X})-valued time series is often written in the form of ((X_{t_{i}})_{i = 0}^{N}), where ((t_{i})_{i = 0}^{N}) is an increasing sequence of time points and (X_{t_{i}} in mathcal{X}) is the time series at time (t_{i}). For example, the trajectories of close price and realised volatility of an index, shown in Figure 1, can be viewed as a (R^2)-valued time series, where the time stamps are given on the x-axis of each subplot.

stock_fig Figure 1: An example of 2-dimensional time series: the evolution of close price and realised volatility of the Dow Jones Industrial Average index (DJI).

A key feature of time series is that the order matters. For example, if positive news about a company precedes negative news, the future stock price of this company will likely go down. In contrast, if the order of the news reverses, one would expect the stock price will increase. Therefore, a question that naturally emerges is how to design neural network architecture to capture such sequential information effectively.

Recurrent Neural Network (RNN) is a popular class of neural network models, which exhibits the strength of analysing time series data. Let’s explain the intuition of the RNNs. Suppose that we translate an English sentence into French. To predict the (n^{th}) French word accurately, it needs not only the (n^{th}) English word, but also the semantics ( ‘’ memory ‘’ ) of the previous English words. In a similar manner, RNNs have hidden neurons with a built-in recurrence structure, which serve the ‘’ memory ‘’ of input time series and lead to better model performance on time series.

Indeed, RNN and its variants have empirically proved useful and delivered excellent performance in diverse sequential data tasks, such as online handwritten text recognition, speech recognition [1], and natural language processing [2]. The financial applications of RNN-based models, such as limit order book prediction [3] and learning optimal hedging strategy [4], are emerging due to the potential performance boost over traditional methods.

In the next step, you will learn the mathematical formulation of RNNs.

References

[1] Graves, A., Mohamed, A.R. and Hinton, G., 2013, May. Speech recognition with deep recurrent neural networks. In 2013 IEEE international conference on acoustics, speech and signal processing (pp. 6645-6649). IEEE.

[2] Wang, S. and Jiang, J., 2016. Learning Natural Language Inference with LSTM. In Proceedings of NAACL-HLT (pp. 1442-1451).

[3] Sirignano, J. and Cont, R., 2019. Universal features of price formation in financial markets: perspectives from deep learning. Quantitative Finance, 19(9), pp.1449-1459.

[4] Buehler, H., Gonon, L., Teichmann, J. and Wood, B., 2019. Deep hedging. Quantitative Finance, 19(8), pp.1271-1291.

This article is from the free online

An Introduction to Machine Learning in Quantitative Finance

Created by
FutureLearn - Learning For Life

Reach your personal and professional goals

Unlock access to hundreds of expert online courses and degrees from top universities and educators to gain accredited qualifications and professional CV-building certificates.

Join over 18 million learners to launch, switch or build upon your career, all at your own pace, across a wide range of topic areas.

Start Learning now