| With the development of economic globalization,the USD/CNY exchange rate has become increasingly important in China’s financial markets.Effective USD/CNY exchange rate prediction can help people analyze the economic situation and avoid financial risks.Because the USD/CNY exchange rate has the characteristics of nonstationarity,nonlinearity and complexity.Exchange rate prediction has become one of the challenging research directions in the financial field.Therefore,it is of great practical significance to establish a highly accurate USD/CNY exchange rate prediction system.In this paper,an improved CNN-STLSTM-AM exchange rate prediction model is proposed to predict the closing price of the USD/CNY exchange rate on the next trading day.The model consists of convolutional neural networks(CNN),special tanh long short-term memory(STLSTM)and attention mechanism(AM).STLSTM is proposed in this paper as an improved deep learning model.The tanh+0.2 function is introduced into the input gate of long short-term memory(LSTM).After introducing the tanh+0.2 function,the output value of the input gate is transformed,and the retention ratio of the data of the input gate is changed.Therefore,STLSTM can more effectively mine the dependencies between financial time series data.CNN is used to extract the features of the input financial time series data,and the important feature data is selected.STLSTM calculates the output data of the selected feature data in time series.At the same time,AM is introduced to calculate the impact of different characteristic data on the closing price of the USD/CNY exchange rate to determine which part of characteristic data needs to be focused on.The experimental data in this paper is the data of the USD/CNY exchange rate and impact factors from January 2,2013,to December 30,2022,which are obtained through the API interface provided by the third-party financial data website Tushare.To verify the effectiveness of the improved CNN-STLSTM-AM prediction model,CNN,LSTM,gated recurrent unit(GRU),CNN-LSTM,CNN-GRU,CNN-LSTM-AM and CNN-GRU-AM are compared by experiments in this paper.Experiments results show that the mean absolute error(MAE)and root mean square error(RMSE)of CNN-STLSTM-AM are the smallest,and R-square(R~2)is the closest to 1.Therefore,the CNN-STLSTM-AM model has high prediction accuracy in exchange rate prediction.By the Python language and Django framework,the USD/CNY exchange rate prediction system based on CNN-STLSTM-AM is designed and implemented.The system realizes the functions of data acquisition,data display and exchange rate prediction.The system can regularly update the data of the USD/CNY exchange rate and impact factors,display the exchange rate data graphically through the Echarts component,and predict the closing price of the USD/CNY exchange rate on the next trading day through the CNN-STLSTM-AM prediction model. |