Stock prices forecasting has always been a challenging task. Although many research projects adopt machine learning and deep learning algorithms to address the problem, few of them pay attention to the varying degrees of dependencies between stock prices. In this paper we introduce a hybrid model that improves stock price prediction by emphasizing the dependencies between adjacent stock prices. The proposed model, ResNLS, is mainly composed of two neural architectures, ResNet and LSTM. ResNet serves as a feature extractor to identify dependencies between stock prices across time windows, while LSTM analyses the initial time-series data with the combination of dependencies which considered as residuals. In predicting the SSE Composite Index, our experiment reveals that when the closing price data for the previous 5 consecutive trading days is used as the input, the performance of the model (ResNLS-5) is optimal compared to those with other inputs. Furthermore, ResNLS-5 outperforms vanilla CNN, RNN, LSTM, and BiLSTM models in terms of prediction accuracy. It also demonstrates at least a 20% improvement over the current state-of-the-art baselines. To verify whether ResNLS-5 can help clients effectively avoid risks and earn profits in the stock market, we construct a quantitative trading framework for back testing. The experimental results show that the trading strategy based on predictions from ResNLS-5 can successfully mitigate losses during declining stock prices and generate profits in the periods of rising stock prices.
翻译:股票价格预测始终是一项具有挑战性的任务。尽管许多研究采用机器学习和深度学习算法来解决这一问题,但鲜有关注股票价格之间不同程度依赖关系的研究。本文提出了一种混合模型,通过强调相邻股票价格之间的依赖关系来改进股价预测。所提出的ResNLS模型主要由两种神经网络架构——ResNet和LSTM组成。ResNet作为特征提取器,用于识别跨时间窗口的股票价格间依赖关系;而LSTM则结合被视为残差的依赖关系,对初始时序数据进行分析。在对上证综合指数的预测实验中,我们发现当使用前5个连续交易日的收盘价数据作为输入时,模型(ResNLS-5)的性能优于其他输入条件下的表现。此外,在预测精度方面,ResNLS-5优于传统的CNN、RNN、LSTM和BiLSTM模型,并且相较当前最优基线方法至少提升了20%的性能。为验证ResNLS-5能否帮助客户在股票市场中有效规避风险并获取收益,我们构建了一个量化交易框架进行回测。实验结果表明,基于ResNLS-5预测结果的交易策略能够在股价下跌时成功减少损失,并在股价上涨期间产生收益。