APP下载

基于深度模型股指预测研究

2021-02-28董世鹏

现代信息科技 2021年16期

摘  要:在长短期记忆网络(LSTM)中引入自注意力机制应用于股票指数预测中,使模型可以处理不同时期的权值,加强了模型对历史数据趋势信息的提取能力。利用LSTM和Attention机制结合的LSTM-Attention神经网络应用于股票预测,对沪深300指数近10年数据进行预测研究。实验结果表明,在LSTM改进的神经网络LSTM-Attention的预测效果优于传统LSTM神经网絡模型的预测效果。

关键词:自注意力机制;股票指数预测;长短期记忆网络

中图分类号:TP181                   文献标识码:A文章编号:2096-4706(2021)16-0100-03

Research on Stock Index Forecast Based on Deep Model

DONG Shipeng

(Hebei University of Economics and Business, Shijiazhuang  050061, China)

Abstract: The introduction of the self-attention mechanism in the Long Short-Term Memory (LSTM) is applied to the stock index prediction, so that the model can handle the weights of different periods, and it strengthens the model’s ability to extract historical data trend information. The LSTM-Attention neural network combined with the LSTM and Attention mechanism is applied to stock forecasting, and the data of the Shanghai and Shenzhen 300 index in the past 10 years is used for forecasting research. The experimental results show that the prediction effect of the LSTM-improved neural network LSTM-Attention is better than that of the traditional LSTM neural network model.

Keywords: self-attention mechanism; stock index prediction; Long Short-Term Memory

0  引  言

股票指数又名为股票价格指数,是一种由证券交易所或金融服务机构编制的反映股市行情的参考数值,可以作为一个国家经济形式的综合反映。由于我国股票市场多为散户,易受到多种因素的影响,致使股票市场内部变化规律繁杂,稳定性差,造成股票价格剧烈波动[1]。因此,如果能对股票价格进行较为准确的预测,引到股市良好的运行,最终将为金融市场的健康发展打下较为牢靠的基础。

金融市场的预测方法大体上可分为基于时间序列模型的预测方法和基于机器学习的预测方法。但由于股票数据具有高噪声、高不确定性、非线性和非平稳性等特定,使得传统的时间序列预测模型难以精确预测股票指数的变化[2]。因此本文主要是基于机器学习预测模型进行股票指数预测。

1  研究方法

1.1  LSTM模型基本理论

LSTM神经网络是一种循环神经网络,主要是为了解决时间序列数据在训练过程中的梯度消失和梯度爆炸的问题,相比于BP神经网络,LSTM神经可以在更长的序列中取得更好的效果,能够对有价值的信息进行长期的记忆[3]。……

登录APP查看全文