Channel and Spatial Attention CNN: Predicting Price Trends from Images
36 Pages Posted: 2 Aug 2022
Date Written: July 27, 2022
Deep learning has been successfully applied for predicting asset prices using financial time series data. However, image-based deep learning models excel at extracting spatial information from images and their potential in financial applications has not been fully explored. Here we propose a new model---channel and spatial attention convolutional neural network (CS-ACNN)---for price trend prediction that takes arbitrary images constructed from financial time series data as input. The model incorporates attention mechanisms between convolutional layers to focus on specific areas of each image that are the most relevant for price trends. CS-ACNN outperforms benchmarks on exchange-traded funds (ETF) data in terms of both model classification metrics and investment profitability, achieving out-of-sample Sharpe ratios ranging from 1.57 to 3.03 after accounting for transaction costs. In addition, we confirm that the images constructed based on our methodology lead to better performance when compared to models based on traditional time series data. Finally, the model learns visual patterns that are consistent with traditional technical analysis, providing an economic rationale for learned patterns and allowing investors to interpret the model.
Keywords: Price trend prediction, Convolutional neural network (CNN), Attention, Image, Interpretability
JEL Classification: G12, G17, C45, C53
Suggested Citation: Suggested Citation