首页 | 本学科首页   官方微博 | 高级检索  
     

基于Pytorch的LSTM模型对股价的分析与预测
引用本文:张康林,叶春明,李钊慧,王锦文. 基于Pytorch的LSTM模型对股价的分析与预测[J]. 计算机技术与发展, 2021, 0(1)
作者姓名:张康林  叶春明  李钊慧  王锦文
作者单位:上海理工大学管理学院;南昌大学公共管理学院
基金项目:国家自然科学基金资助项目(71840003);上海理工大学科技发展资助项目(2018KJFZ043)
摘    要:股价预测一直都是股票投资者重点关注和重点研究的方向,针对股价具有高度非线性、高噪声、动态性等问题,提出一种基于自组织特征映射(SOM)神经网络和长短期记忆网络(LSTM)共同应用的股价预测方法。第一步聚类,使用python语言实现改进的自组织特征映射神经网络算法,将187支股票分成三类,三类股票以盈利能力大小进行聚类,并且求出每一类所包含的股票代码;第二步预测,基于Pytorch深度学习框架构造长短期记忆网络模型,分别对每一类中随机的3支股票进行股价预测,再通过均方误差和决定系数对预测结果进行评价。结果表明,在使用相同的预测模型对不同盈利能力的股票做股价预测时,盈利能力越大的股票,预测精度越高。此研究可以为投资者筛选出盈利能力更大的股票,并且在提高股价预测精度上也具有一定的贡献。

关 键 词:Pytorch  自组织特征映射  长短期记忆网络  股票价格  聚类  预测

Analysis and Forecast of Stock Price Based on LSTM Model of Pytorch
ZHANG Kang-lin,YE Chun-ming,LI Zhao-hui,WANG Jin-wen. Analysis and Forecast of Stock Price Based on LSTM Model of Pytorch[J]. Computer Technology and Development, 2021, 0(1)
Authors:ZHANG Kang-lin  YE Chun-ming  LI Zhao-hui  WANG Jin-wen
Affiliation:(Bussiness School of University of Shanghai for Science and Technology,Shanghai 200093,China;Public Administration School of Nanchang University,Nanchang 330000,China)
Abstract:Stock price prediction has always been the focus and research direction of stock investors.Aiming at the problems of highly nonlinear,high noise and dynamic of stock prices,a new stock price prediction method based on self-organizing feature map(SOM)neural network and long-short term memory(LSTM)is proposed.The first step is clustering,with python to implement an improved self-organizing feature mapping neural network algorithm.The 187 stocks are divided into three categories.The three types of stocks are clustered according to their profitability,and the stock codes included in each category are obtained.The second step of prediction is to construct a long-term and short-term memory network model based on the Pytorch deep learning framework,to predict the stock price of three random stocks in each class,and then to evaluate the prediction results by means of mean square error and determination coefficient.The results show that when using the same prediction model to make stock price predictions for stocks with different profitability,stocks with greater profitability have higher prediction accuracy.This research can screen out stocks with greater profitability for investors,and also contribute to improving the accuracy of stock price prediction.
Keywords:Pytorch  self-organizing map  long-short term memory  share price  cluster  prediction
本文献已被 维普 等数据库收录!
设为首页 | 免责声明 | 关于勤云 | 加入收藏

Copyright©北京勤云科技发展有限公司  京ICP备09084417号