# Deep Learning Algorithm-Based Financial Prediction Models

Authors: Helin Jia
Journal: Complexity
 (2021)

---

## Abstract

In this paper, a new FEPA portfolio forecasting model is based on the EMD decomposition method. The model is based on the special empirical modal decomposition of financial time series, principal component analysis, and artificial neural network to model and forecast for nonlinear, nonstationary, multiscale complex financial time series to predict stock market indices and foreign exchange rates and empirically investigate this hot area in financial market research. The combined forecasting model proposed in this paper is based on the idea of decomposition-reconstruction synthesis, which effectively improves the model’s prediction of internal financial time series. In this paper, we select the CSI 300 Index and foreign exchange rate as the empirical market and data and establish seven forecasting models to make predictions about the short-term running trend of the closing price. The interval EMD decomposition algorithm is introduced in this paper, considering both high and low prices to be contained in the input and output. By analyzing the closing price, high and low prices of the stock index at the same time, the volatility of this interval time series of the index and its trend can be better captured.


---

## Body

## 1. Introduction

Despite the rapid development of information science and technology and computer networks in the past mortal decade, interdisciplinary research promoting cross fertilization of disciplines, and the application of research methods used in many other disciplines to the financial market forecasting, it is still very difficult to predict the current and future of financial markets. Financial market forecasting is a challenging research topic due to the support of existing financial market theories, as well as the linkage between global financial markets and the specificity of the forecasting time horizon [1]. The author feels that the main reasons for the difficulty of financial market forecasting are the financial market itself is a nonlinear, nonstationary, multiscale interval time series, and there are many noisy trading components.After the reform and opening up, China’s capital market from the creation to the continuous development and improvement, the level of income of residents continues to rise, and more and more individual investors invest in the foreign exchange market, hoping to obtain higher returns through the foreign exchange market [2]. Although a foreign exchange may bring higher returns compared to other investment varieties, along with its superior returns is a high risk, and foreign exchange prices are unpredictable changes which make investors feel the complexity of this market [3]. To obtain better investment returns and avoid investment risks, people urgently need a scientific forecasting method to guide their investments and must find a theory to explain the causes of price movements. Although financial market price forecasting is a global challenge, huge economic potential benefits contained in this research have attracted many experts and scholars around the world to study it [4].Since the birth of financial markets, people have sought ways to predict changes in asset prices. Whether in the past, present, or future, forecasting has been an intriguing and challenging research topic. In ancient societies, due to the limited ability to understand the objective world, people usually used natural signs of change to organize their travels, farming, and harvesting [5]. In the modern society, scholars use various mathematical models to predict the future by collecting historical data and putting them into mathematical models for training and then modifying the corresponding mathematical models by constantly adjusting the errors between the prediction results and the real values. These make prediction science a romantic art [6].The investors involved in the market have different investment styles and trading strategies; investors are not all rational; in the Chinese stock market, there are many retail investors, and there is a lack of many institutional investors, and most investors’ investment behavior is blind and arbitrary, and with personal emotional fluctuations, these investment behaviors converge to form a super complex dynamics system [7]. The foreign exchange index series is a very complex interval financial time series with numerous noises, and it is self-evidently difficult for the author to use special data mining methods to extract valid historical information sets from this complex interval time series and build mathematical models to predict the future trend of the stock index. Despite this, financial forecasting has made great progress [8, 9]. The main nonlinear mathematical models currently used to forecast financial markets are artificial neural networks, support vector machines, genetic algorithms, wavelet analysis, and empirical model analysis. An artificial neural network is a nonlinear mathematical model that expresses complex financial markets accurately and simulates them well. The use of neural networks to build forecasting models is not a modern theory in the last three decades [10]. As shown in Figure 1, many of the combinatorial models that people build now to predict financial markets are still based on artificial intelligence neural networks, which remain as a hot area of research and a challenging topic for experts and scholars.Figure 1
Deep learning algorithm based on the linear correlation coefficient when the partial correlation coefficient is considered in the first period.To find and build a more accurate model for financial market forecasting, scholars have invested a lot of effort into the algorithms of mathematical models and developed various neural networks based on unique algorithms [11]. For example, feedforward neural networks (BP neural networks) based on error backpropagation algorithms, linear neural networks, radial basis function neural networks, probabilistic neural networks, stochastic neural networks, and feedback neural networks [12]. The author believes that the previous research results show that the mathematical model of the neural network itself has made great progress; if you want to innovate the algebraic model algorithm, it requires very deep mathematical theory [13]. Therefore, the main innovation of this paper is to increase the input and output of neural networks with the latest data mining techniques and sampling methods [14].Data mining technology is a multidisciplinary intersection field that emerged in the late 1980s and has made considerable progress since then. With the further development of information technology and big data analysis, the novelty of knowledge is required more and more, and the traditional data mining cannot meet the requirements for data analysis of dynamic data sources or dynamic environments, and the research of dynamic data mining becomes more and more important [15]. Based on traditional data mining techniques, this paper improves the data processing process of dynamic data mining [16]. Dynamic data mining is to find out valuable knowledge and to be able to process diverse real-time data in a timely and dynamic manner; whereas traditional data mining is only performed for a fixed dataset. Data mining from a business perspective is to analyze and explore big data such as corporate data to reveal unknown and hidden business operation laws following the established business objectives of the enterprise [17]. Data mining technology can only have an application value if it is directed to a specific business field. The knowledge and laws discovered by data mining are relative and can only guide specific business behavior, not requiring the discovery of universal truth [18]. Therefore, data mining technology is an interdisciplinary discipline that provides decision support and improves the application of data [19].This paper introduces empirical modal decomposition signal processing for financial time series. It covers the differences between empirical modal analysis and other decomposition algorithms, describes the working principle of the sliding window for data preprocessing, and then focuses on the principle of EMD decomposition, including EMD decomposition process, instantaneous frequency, ephemeral function, screening process, completeness, and orthogonality [20]. Then, the EMD decomposition process based on interval-type time series is introduced. The EMD decomposition algorithm is the basis for constructing the FEPA model and the reference EMD-BPNN model. The extraction of principal components after EMD decomposition is the key step of the FEPA model. For the CSI 300 Index, several forecasting models are built in this paper model, and the forecasting effect and empirical analysis of various models are described, including data sources, analysis of empirical results, eigenvalues and cumulative contribution rates after principal component analysis, performance criteria of forecasting models, empirical results, and discussion [21]. The FEPA model is also compared with the reference model selected in this paper. The empirical results show that the FEPA model has significantly higher forecasting performance compared with linear models such as ARIMA. Compared with the EMD-BPNN model, the FEPA model also improves to some extent.


## 2. A General Architecture for Deep Learning in Financial Market Forecasting

### 2.1. FEPA Model Principles and Structure

In general, the foreign exchange market price time series fluctuates stochastically and has nonlinear, nonstationary, and multiscale characteristics. These characteristics bring many difficulties to forecast foreign exchange market prices. General forecasting methods are usually difficult to capture the complex and variable characteristics of data fluctuations, which reduce forecasting accuracy. To study the pattern of price fluctuations in the foreign exchange market, scholars have proposed a good idea: completely decompose the original data series, and then, analyze the characteristics of all decomposed series [22, 23]. In this paper, a novel FEPA model is proposed by combining empirical modal decomposition algorithm, principal component analysis, and neural network. CFTSEMD-PCA-ANN firstly applies the sliding window to extract the original financial time series to obtain the dataset for decomposition and then applies the EMD decomposition algorithm to decompose the dataset into different scales of essential functions, and on this basis, the principal component analysis algorithm is applied to decompose it; we apply the EMD decomposition algorithm to decompose the dataset into eigenmodes at different scales and apply the principal component analysis algorithm to reduce the dimensionality of the decomposed data and compress the redundant data. The combined prediction model proposed in this paper assumes of decomposition reconstruction one-by-one integration, which improves the learning ability of the model for financial time series and multiple objective functions and effectively improves the prediction accuracy. The propagation neural network is proposed in this paper. The FEPA model mainly involves forward-rolling EMD decomposition algorithm, principal component analysis, and inverse. The overall flow chart of this model is shown in Figure 2.Figure 2
Algorithm flow chart of the FEPA combined prediction model.As seen from the flow chart above, the FEPA combined prediction model uses the EMD decomposition algorithm to adapt to the nonlinear and stochastic characteristics of financial data, which can solve the financial prediction problem; then, the principal component analysis is used to dimensionality reduction of IMF components to extract the most effective data information to reduce noise disturbance, and the dimensionality reduction process effectively reduces redundant data and improves the response speed of the model. Data obtained from the dimensionality reduction are input into the neural network model for training, to take advantage of the wide adaptation range and good prediction performance of the neural network model. Therefore, the FEPA model retains the advantages of both the EMD decomposition algorithm and the neural network model. In this paper, the dimensionality reduction by principal component analysis improves the model response speed and considers the requirements of fast and accurate financial forecasting, and the FEPA model is a more ideal forecasting model from the theoretical point of view.


### 2.2. Price Time-Scale Space for Financial Time Series

Financial time series analysis deals with discrete time series in most cases, which have multiscale spatial characteristics depending on the sampling frequency of the data. The raw time series data can be subdivided into regular time series with time intervals of the corresponding time scales. For example, TS is hourly data, each time interval is one hour, and all transactions within one hour are considered as one data point, from which four component values are extracted: the opening price, high price, low price, and closing price. For the price xx in the time interval, we use the four components to represent its structure:(1)xk=x.Ok×x.hkx.lk×x.ck.x⋅Ok represents the opening price, x⋅he represents the highest price, x⋅lb represents the lowest price, and x⋅Ck represents the closing price. For most financial markets, the volume for each time interval within any selected time scale can be used for data mining. Thus, information for xc within time interval k includes the volume x⋅vk, and for each time scale, the yin and yang volatility of the price time series can be calculated. Yin-yang volatility is a novel method of calculating volatility. It divides the financial time series into an up period and a down period and calculates the positive and negative volatility separately. The combination of positive volatility and negative volatility is called yin-yang volatility. For a price time series x0, x1, …, xn, the yin-yang volatility σ is defined as(2)σn=∑i=0m−1xn−1−xn−2m×δxn−i.The definition of yin-yang volatility depends on one parameter: the length of the moving average periodm. The information reflected in yin-yang volatility is fundamentally dependent on how the moving average is defined. For a typical financial price time series, there are four simple yin and yang volatility, including the closing price, the high price, the low price, and the typical price. It is worth noting that, in an uptrend, the highest price positive volatility is much greater than the minimum price negative volatility, and in a downtrend, the opposite is true. The minimum price negative volatility is much greater than the maximum price positive volatility. The study of time scale space provides a good reference point for Forex analysts and fund managers; professional traders widely use various time scale-space data. On each of the commonly used time scales, many traders make trading decisions based on the relevant scale space. Price and time scale to define the price-time scale space. Researchers can do EMD decomposition as well as calculate its yin and yang volatility on each of the commonly used time scales as needed. Thus, it is possible to catch some subtle information about financial time series and provide trading strategies for short-term trading.For an original modelS (t), the IMF of the order K is obtained after EMD decomposition:(3)st=∑k=0kIMFktrkt.The IMFs of each level are not obtained by explicit convolutional computation, but by an algorithm. After we obtain the IMFs of each level of the algorithm, we can treat each IMF as a decomposition sequence and substitute it into the deep split-combination neural network model architecture to construct a complete deep split-combination neural network model based on empirical modal decomposition. Here, the concept of level is generated by multiple iterations of EMD of the data itself, so it does not cover a strict time scale level, but it is also a scale-space representation reflecting the characteristics of local oscillations. First, for the basic RNN, it can handle certain short-term dependencies, but it cannot handle long-term dependencies. The hidden layer information of the RNN at this moment only comes from the current input and the hidden layer information of the previous moment and has no memory function. To solve the long-term dependence of RNN, that is, the problem of gradient disappearance, LSTM came into being. LSTM introduces the sigmoid function through the input gate, forget gate, and output gate, combined with the tanh function, and adds a summation operation to reduce the possibility of gradient disappearance and gradient explosion.The original time seriesx (t) can then be decomposed into the synthesis of the inverse transform of the discrete wavelet transform:(4)xt=∑mWTxi,j×∑nΨi,jt.


## 2.1. FEPA Model Principles and Structure

In general, the foreign exchange market price time series fluctuates stochastically and has nonlinear, nonstationary, and multiscale characteristics. These characteristics bring many difficulties to forecast foreign exchange market prices. General forecasting methods are usually difficult to capture the complex and variable characteristics of data fluctuations, which reduce forecasting accuracy. To study the pattern of price fluctuations in the foreign exchange market, scholars have proposed a good idea: completely decompose the original data series, and then, analyze the characteristics of all decomposed series [22, 23]. In this paper, a novel FEPA model is proposed by combining empirical modal decomposition algorithm, principal component analysis, and neural network. CFTSEMD-PCA-ANN firstly applies the sliding window to extract the original financial time series to obtain the dataset for decomposition and then applies the EMD decomposition algorithm to decompose the dataset into different scales of essential functions, and on this basis, the principal component analysis algorithm is applied to decompose it; we apply the EMD decomposition algorithm to decompose the dataset into eigenmodes at different scales and apply the principal component analysis algorithm to reduce the dimensionality of the decomposed data and compress the redundant data. The combined prediction model proposed in this paper assumes of decomposition reconstruction one-by-one integration, which improves the learning ability of the model for financial time series and multiple objective functions and effectively improves the prediction accuracy. The propagation neural network is proposed in this paper. The FEPA model mainly involves forward-rolling EMD decomposition algorithm, principal component analysis, and inverse. The overall flow chart of this model is shown in Figure 2.Figure 2
Algorithm flow chart of the FEPA combined prediction model.As seen from the flow chart above, the FEPA combined prediction model uses the EMD decomposition algorithm to adapt to the nonlinear and stochastic characteristics of financial data, which can solve the financial prediction problem; then, the principal component analysis is used to dimensionality reduction of IMF components to extract the most effective data information to reduce noise disturbance, and the dimensionality reduction process effectively reduces redundant data and improves the response speed of the model. Data obtained from the dimensionality reduction are input into the neural network model for training, to take advantage of the wide adaptation range and good prediction performance of the neural network model. Therefore, the FEPA model retains the advantages of both the EMD decomposition algorithm and the neural network model. In this paper, the dimensionality reduction by principal component analysis improves the model response speed and considers the requirements of fast and accurate financial forecasting, and the FEPA model is a more ideal forecasting model from the theoretical point of view.


## 2.2. Price Time-Scale Space for Financial Time Series

Financial time series analysis deals with discrete time series in most cases, which have multiscale spatial characteristics depending on the sampling frequency of the data. The raw time series data can be subdivided into regular time series with time intervals of the corresponding time scales. For example, TS is hourly data, each time interval is one hour, and all transactions within one hour are considered as one data point, from which four component values are extracted: the opening price, high price, low price, and closing price. For the price xx in the time interval, we use the four components to represent its structure:(1)xk=x.Ok×x.hkx.lk×x.ck.x⋅Ok represents the opening price, x⋅he represents the highest price, x⋅lb represents the lowest price, and x⋅Ck represents the closing price. For most financial markets, the volume for each time interval within any selected time scale can be used for data mining. Thus, information for xc within time interval k includes the volume x⋅vk, and for each time scale, the yin and yang volatility of the price time series can be calculated. Yin-yang volatility is a novel method of calculating volatility. It divides the financial time series into an up period and a down period and calculates the positive and negative volatility separately. The combination of positive volatility and negative volatility is called yin-yang volatility. For a price time series x0, x1, …, xn, the yin-yang volatility σ is defined as(2)σn=∑i=0m−1xn−1−xn−2m×δxn−i.The definition of yin-yang volatility depends on one parameter: the length of the moving average periodm. The information reflected in yin-yang volatility is fundamentally dependent on how the moving average is defined. For a typical financial price time series, there are four simple yin and yang volatility, including the closing price, the high price, the low price, and the typical price. It is worth noting that, in an uptrend, the highest price positive volatility is much greater than the minimum price negative volatility, and in a downtrend, the opposite is true. The minimum price negative volatility is much greater than the maximum price positive volatility. The study of time scale space provides a good reference point for Forex analysts and fund managers; professional traders widely use various time scale-space data. On each of the commonly used time scales, many traders make trading decisions based on the relevant scale space. Price and time scale to define the price-time scale space. Researchers can do EMD decomposition as well as calculate its yin and yang volatility on each of the commonly used time scales as needed. Thus, it is possible to catch some subtle information about financial time series and provide trading strategies for short-term trading.For an original modelS (t), the IMF of the order K is obtained after EMD decomposition:(3)st=∑k=0kIMFktrkt.The IMFs of each level are not obtained by explicit convolutional computation, but by an algorithm. After we obtain the IMFs of each level of the algorithm, we can treat each IMF as a decomposition sequence and substitute it into the deep split-combination neural network model architecture to construct a complete deep split-combination neural network model based on empirical modal decomposition. Here, the concept of level is generated by multiple iterations of EMD of the data itself, so it does not cover a strict time scale level, but it is also a scale-space representation reflecting the characteristics of local oscillations. First, for the basic RNN, it can handle certain short-term dependencies, but it cannot handle long-term dependencies. The hidden layer information of the RNN at this moment only comes from the current input and the hidden layer information of the previous moment and has no memory function. To solve the long-term dependence of RNN, that is, the problem of gradient disappearance, LSTM came into being. LSTM introduces the sigmoid function through the input gate, forget gate, and output gate, combined with the tanh function, and adds a summation operation to reduce the possibility of gradient disappearance and gradient explosion.The original time seriesx (t) can then be decomposed into the synthesis of the inverse transform of the discrete wavelet transform:(4)xt=∑mWTxi,j×∑nΨi,jt.


## 3. Forecast Analysis of CSI 300 Index Empirical Results

### 3.1. FEPA Model for Predicting CSI 300 Index and Empirical Results

Price movements are a result of information, so the study of market price movements has always been a hot topic in finance research. In recent years, with the continuous development of research and econometrics, researchers have begun to focus on how to make full use of the existing trading information to study financial markets and have achieved a wealth of research results. Long before economists conducted theoretical research on financial markets, investment traders have been concerned with how to understand the market and predict the market from the price changes in the pattern [24]. For many years, foreign exchange prices have been an important factor in the performance of the global or a country’s economy. Fluctuations in foreign exchange prices have a significant effect on the economies of countries around the world. As a result, the functioning of foreign exchange prices is a constant concern for economic experts in most industries and many politicians. Market predictability is closely related to the efficiency of market operation, and an in-depth study of the predictability of financial asset prices not only helps to understand the functioning mechanism and operational efficiency of financial markets but also plays an important role in guiding investors in making investment decisions. In this paper, we will utilize several forecasting models including the FEPA model to test the CSI 300 Index and compare the forecasting performance of these models with that of the FEPA model.The CSI 300 Index is a representative index of the major constituent stocks in Shanghai and Shenzhen, reflecting the overall operation of the Shanghai and Shenzhen stock markets. At this time, the China Securities Regulatory Commission (CSRC) was initiating the equity share reform, and after the events such as the reduction of controlling shareholders’ small and large nonequity holdings, the operation of listed companies became more standardized, and the management further strengthened the financial risk regulation. After the completion of the shareholding reform, China’s stock market gradually moved towards a mature development path and converged with the operation mechanism of developed countries. The sample collection period of the empirical dataset in this paper is the recent years, excluding the influence of holidays and other factors. All the sample experimental data can be divided into two subsets: the training set and the test set. The first 1000 data are the training set, and the last 250 data are the best set, depicting the daily chart of the closing price of the index. The period of the sample covers many unexpected events and financial crises, which are sufficient for training the model. The closing price of CSI 300 indexes is statistically described, and the results are shown in Figure3.Figure 3
Daily chart of the closing price of the CSI 300 Index.EMD’s cubic spline interpolation algorithm and sieving process ensure that the individual IMF series after decomposition is orthogonal to each other. In this chapter, the EMD decomposition algorithm decomposes the CSI 300 Index from a nonlinear nonstationary signal into a series of IMF components and a trend term. Figure4 shows the plot of IMF components and trend term of the CSI 300 Index. Increasing the number of layers of IMF series for EMD decomposition will, on the one hand, make the approximate and detailed signals better and improve the prediction accuracy; on the other hand, the computational error brought by the decomposition process will increase as the number of decomposition layers increases, and the prediction performance will decrease as a result, so it is very important to choose the appropriate number of decomposition layers. Each IMF component reflects the fluctuation characteristics of investor sentiment at different frequencies, where the high-frequency IMF1 reflects the fluctuation characteristics of investor sentiment during short-term operations, the low-frequency IMF1 reflects the fluctuation characteristics of investor sentiment during medium-term operations, and the trend term reflects the overall trend of investor sentiment.Figure 4
IMF component chart of the closing price of the CSI 300 Index.In the discussion of the analysis of the empirical results of the CSI 300 Index, before conducting the principal component analysis, factor analysis was performed using SPSS, and the value of KMO was 0.7032, which was greater than 0.5, satisfying the conditions for conducting the principal component analysis. Feature extraction refers to the mapping process of downscaling and removing the effect of noise from the data. Among the numerous methods of feature extraction, principal component analysis is the most common. Principal component analysis converts high-dimensional correlated input vectors into low-dimensional mutually uncorrelated principal components, and the corresponding feature vectors are calculated based on the covariance matrix of the original data to obtain the principal components. In this paper, we propose arranging the IMF series after forward-rolling EMD decomposition into a matrix and then reduce the dimensionality by the principal component algorithm. Figure4 plots the logarithm of the eigenvalues of the CSI 300 Index. It can be observed that the cumulative contribution of the variance of the principal components corresponding to the first four eigenvalues of the IMF series of the CSI 300 Index after the principal component analysis is over 85%. To obtain better prediction results, the opening 22 principal components of the CSI 300 Index are extracted as training data and input to the neural network in this paper.


### 3.2. An Empirical Analysis of the Prediction Effect of the Interval EMD Decomposition Model

Even though there have been many interesting results in the academic research on market predictability, the methodologies used in these studies suffer from a lack of information utilization. In the existing literature on market predictability, there is no doubt that only the closing price information is utilized, while additional information carried by the trading price, such as the high and low prices, is ignored. In this paper, the forward-rolling EMD decomposition algorithm in the FEPA model is replaced by an interval EMD decomposition algorithm, and this latest model is referred to as the interval EMD model in this paper. In this section, the interval EMD model is used to test the short-term trend of the closing price, the highest price, and the lowest price of the CSI 300 Index, and the interval EMD model is compared with several other models to test the performance of the interval EMD model. The empirical dataset, like the previous section, is also the CSI 300 Index, and the closing, high, and low prices of this index are tested. The sampling time of the dataset in this section is also the same as in the previous section. The CSI 300 Index sample collection period is from 2016 onwards, excluding the effects of holidays and other factors, and there are 1250 sets of data for each market, respectively, including the statistical characteristics of the closing, highest, and lowest prices of the CSI 300 Index. The dailyK-line chart of the CSI 300 Index at the beginning of the dataset period is illustrated in Figure 5.Figure 5
CSI 300 dailyK-line chart.As more and more variables are found to have the ability to forecast financial market prices, researchers are beginning to believe that financial markets are predictable. This section compares the forecasting results of the interval EMD model with the FEPA model. The results of the performance measures and performance comparisons of the forecasting models selected in this section for predicting closing prices are given in Figure6, respectively, to test the forecasting accuracy of each model; the performance criteria selected in this section are the same; MAD, MAPE, and RMSE are error detection indicators, and DS is the percentage of correct stock index direction forecasts, i.e., hit rate. The prediction error values of the interval EMD decomposition method is smaller than those of the FEPA model in detecting the three time series of the closing price, the highest price, and the lowest price. For the highest price of the CSI 300 Index, the prediction error values of the interval EMD decomposition method are 48.5868, 1.05486, and 0.1698 for MAD, MAPE, and RMSE, respectively, which are 12.53%, 13.4%, and 11.91% better than the FEPA model. Meanwhile, the interval EMD decomposition method has a small increase in the hit rate when predicting the closing price of the index. When predicting the closing price of CSI 300 indexes, the interval EMD decomposition method reached 75.3600, which is better than the prediction performance of the FEPA model.Figure 6
Comparison of prediction performance of various models for predicting closing prices.


## 3.1. FEPA Model for Predicting CSI 300 Index and Empirical Results

Price movements are a result of information, so the study of market price movements has always been a hot topic in finance research. In recent years, with the continuous development of research and econometrics, researchers have begun to focus on how to make full use of the existing trading information to study financial markets and have achieved a wealth of research results. Long before economists conducted theoretical research on financial markets, investment traders have been concerned with how to understand the market and predict the market from the price changes in the pattern [24]. For many years, foreign exchange prices have been an important factor in the performance of the global or a country’s economy. Fluctuations in foreign exchange prices have a significant effect on the economies of countries around the world. As a result, the functioning of foreign exchange prices is a constant concern for economic experts in most industries and many politicians. Market predictability is closely related to the efficiency of market operation, and an in-depth study of the predictability of financial asset prices not only helps to understand the functioning mechanism and operational efficiency of financial markets but also plays an important role in guiding investors in making investment decisions. In this paper, we will utilize several forecasting models including the FEPA model to test the CSI 300 Index and compare the forecasting performance of these models with that of the FEPA model.The CSI 300 Index is a representative index of the major constituent stocks in Shanghai and Shenzhen, reflecting the overall operation of the Shanghai and Shenzhen stock markets. At this time, the China Securities Regulatory Commission (CSRC) was initiating the equity share reform, and after the events such as the reduction of controlling shareholders’ small and large nonequity holdings, the operation of listed companies became more standardized, and the management further strengthened the financial risk regulation. After the completion of the shareholding reform, China’s stock market gradually moved towards a mature development path and converged with the operation mechanism of developed countries. The sample collection period of the empirical dataset in this paper is the recent years, excluding the influence of holidays and other factors. All the sample experimental data can be divided into two subsets: the training set and the test set. The first 1000 data are the training set, and the last 250 data are the best set, depicting the daily chart of the closing price of the index. The period of the sample covers many unexpected events and financial crises, which are sufficient for training the model. The closing price of CSI 300 indexes is statistically described, and the results are shown in Figure3.Figure 3
Daily chart of the closing price of the CSI 300 Index.EMD’s cubic spline interpolation algorithm and sieving process ensure that the individual IMF series after decomposition is orthogonal to each other. In this chapter, the EMD decomposition algorithm decomposes the CSI 300 Index from a nonlinear nonstationary signal into a series of IMF components and a trend term. Figure4 shows the plot of IMF components and trend term of the CSI 300 Index. Increasing the number of layers of IMF series for EMD decomposition will, on the one hand, make the approximate and detailed signals better and improve the prediction accuracy; on the other hand, the computational error brought by the decomposition process will increase as the number of decomposition layers increases, and the prediction performance will decrease as a result, so it is very important to choose the appropriate number of decomposition layers. Each IMF component reflects the fluctuation characteristics of investor sentiment at different frequencies, where the high-frequency IMF1 reflects the fluctuation characteristics of investor sentiment during short-term operations, the low-frequency IMF1 reflects the fluctuation characteristics of investor sentiment during medium-term operations, and the trend term reflects the overall trend of investor sentiment.Figure 4
IMF component chart of the closing price of the CSI 300 Index.In the discussion of the analysis of the empirical results of the CSI 300 Index, before conducting the principal component analysis, factor analysis was performed using SPSS, and the value of KMO was 0.7032, which was greater than 0.5, satisfying the conditions for conducting the principal component analysis. Feature extraction refers to the mapping process of downscaling and removing the effect of noise from the data. Among the numerous methods of feature extraction, principal component analysis is the most common. Principal component analysis converts high-dimensional correlated input vectors into low-dimensional mutually uncorrelated principal components, and the corresponding feature vectors are calculated based on the covariance matrix of the original data to obtain the principal components. In this paper, we propose arranging the IMF series after forward-rolling EMD decomposition into a matrix and then reduce the dimensionality by the principal component algorithm. Figure4 plots the logarithm of the eigenvalues of the CSI 300 Index. It can be observed that the cumulative contribution of the variance of the principal components corresponding to the first four eigenvalues of the IMF series of the CSI 300 Index after the principal component analysis is over 85%. To obtain better prediction results, the opening 22 principal components of the CSI 300 Index are extracted as training data and input to the neural network in this paper.


## 3.2. An Empirical Analysis of the Prediction Effect of the Interval EMD Decomposition Model

Even though there have been many interesting results in the academic research on market predictability, the methodologies used in these studies suffer from a lack of information utilization. In the existing literature on market predictability, there is no doubt that only the closing price information is utilized, while additional information carried by the trading price, such as the high and low prices, is ignored. In this paper, the forward-rolling EMD decomposition algorithm in the FEPA model is replaced by an interval EMD decomposition algorithm, and this latest model is referred to as the interval EMD model in this paper. In this section, the interval EMD model is used to test the short-term trend of the closing price, the highest price, and the lowest price of the CSI 300 Index, and the interval EMD model is compared with several other models to test the performance of the interval EMD model. The empirical dataset, like the previous section, is also the CSI 300 Index, and the closing, high, and low prices of this index are tested. The sampling time of the dataset in this section is also the same as in the previous section. The CSI 300 Index sample collection period is from 2016 onwards, excluding the effects of holidays and other factors, and there are 1250 sets of data for each market, respectively, including the statistical characteristics of the closing, highest, and lowest prices of the CSI 300 Index. The dailyK-line chart of the CSI 300 Index at the beginning of the dataset period is illustrated in Figure 5.Figure 5
CSI 300 dailyK-line chart.As more and more variables are found to have the ability to forecast financial market prices, researchers are beginning to believe that financial markets are predictable. This section compares the forecasting results of the interval EMD model with the FEPA model. The results of the performance measures and performance comparisons of the forecasting models selected in this section for predicting closing prices are given in Figure6, respectively, to test the forecasting accuracy of each model; the performance criteria selected in this section are the same; MAD, MAPE, and RMSE are error detection indicators, and DS is the percentage of correct stock index direction forecasts, i.e., hit rate. The prediction error values of the interval EMD decomposition method is smaller than those of the FEPA model in detecting the three time series of the closing price, the highest price, and the lowest price. For the highest price of the CSI 300 Index, the prediction error values of the interval EMD decomposition method are 48.5868, 1.05486, and 0.1698 for MAD, MAPE, and RMSE, respectively, which are 12.53%, 13.4%, and 11.91% better than the FEPA model. Meanwhile, the interval EMD decomposition method has a small increase in the hit rate when predicting the closing price of the index. When predicting the closing price of CSI 300 indexes, the interval EMD decomposition method reached 75.3600, which is better than the prediction performance of the FEPA model.Figure 6
Comparison of prediction performance of various models for predicting closing prices.


## 4. Deep Learning-Based Analysis of Empirical Forex Results’ Prediction

### 4.1. FEPA Models for Predicting Foreign Exchange and Empirical Results

As a monetary variable of international interest, the exchange rate occupies a central position in a country’s economic system, and the stability and development of both domestic and foreign economies are affected to some extent by exchange rate fluctuations. Changes in the exchange rate reflect changes in the economic fundamentals of the international purchasing power of the local currency [25]. As the foreign exchange market is affected by various factors such as the securities market, commodity market, crude oil futures’ market, and import and export trade volume of each country, the magnitude and frequency of exchange rate fluctuations are often beyond the acceptable range of the regulatory authorities, causing a certain impact on the economy and the life of the residents of the country. Since July 2005, China has put in place a floating exchange rate system in which the RMB exchange rate will refer to a basket of currencies and be based on the market supply and demand. In November 2017, the IMF Chairman announced the addition of the RMB to the IMF’s Special Drawing Rights’ currency basket, which clears the way for the internationalization of the RMB. The US dollar, the euro, the Japanese yen, and the British pound are the current SDR basket currencies. After the RMB is added to the SDR basket of currencies, the weight of RMB in the SDR basket of currencies is 10.92%. The weight of other currencies is as follows: the weight of USD is 41.7300. The weight of the euro is 30.9300, ranking second; the weight of the yen is 8.3300, ranking fourth; the weight of the British pound is 8.0900, ranking fifth. According to the information provided by the General Administration of Customs, in the first half of 2018, the United States was our second-largest trading partner after the European Union. Since the US dollar and the euro rank first and second in the weight of the SDR basket of currencies and the EU and the US are our first and second-largest trading partners, respectively, the US dollar against the yuan and the euro against the yuan are selected as the objects of the study in this section when studying foreign exchange. The daily chart of the USD-RMB exchange rate is depicted in Figure 7. The skewness value of all samples of the USD-RMB exchange rate is greater than zero, and the kurtosis value is greater than 2, while the skewness value of all samples of the time series of the EUR-RMB exchange rate is less than zero, and the kurtosis value is greater than 3, which indicates that both the USD-RMB exchange rate and the EUR-RMB exchange rate do not obey normal distribution.Figure 7
USD/CNH daily chart.In this paper, we use the collected data for cross validation after preprocessing and split the whole training set into two parts: the training set and the validation set, while the original test set remains unchanged. Specifically, the entire training process is divided into two steps. First, the FEPA model is trained with the training set, and the hypermastigote is continuously adjusted to achieve good performance of the model in the validation set, and then, the model with confirmed hypermastigote is trained again to minimize the global error between the predicted data and the actual target of the FEPA model by modifying the weights, and finally, the test set is used for prediction and comparison. ANN has a loop connection in the hidden state. This loop constraint can ensure that the sequence information is captured in the input data. The building block of CNN is the filter, which is the kernel. The function of the kernel is to extract relevant features from the input using convolution operations. We can try to understand the importance of using images as input data filters. This article uses the ANN model.As shown in the curves of actual closing prices and predicted data in Figure8, the difference between predicted and actual data is almost zero in the training set, and the distance between the predicted data curves and actual data in the test set is almost none. The FEPA model has a strong generalization ability to effectively train financial price time series to predict series volatility. Besides, Type III is more adaptive than Type I and Type II in the face of the sharp fluctuations in the curves in the test set. Linear regression of the forex price prediction closing price, respectively, corresponds to a good fit of the LSTM model prediction data.Figure 8
Prediction results obtained from the FEPA model training forex data.


### 4.2. Analysis of the Effect of the Time Factor on Forex Deep Learning Prediction Results

The establishment of the FEPA model is the first step in the establishment of the FEPA-EMD model type. Since the prediction value of the FEPA model consists of two parts, the prediction value and the residual prediction value, and the latter residual prediction value is obtained by using the output residual of the FEPA model on the training set as the FEPA training object, the fitting effect of the FEPA model will affect the fitting effect of the hybrid model. The selection of appropriate parameters and the establishment of an effective FEPA model are necessary for the successful establishment of the hybrid model. To verify whether the fitted FEPA model has good applicability, 1200 days of rolling prediction based on the true value is performed, and after each prediction of the latter day’s data, the true value of the latter day is added to the training dataset and then predicted, and the prediction result is 0.057043. Since each prediction is based on the exact value, the model can fit the changing trend of the original data, and the model is reasonably established. The model can be used to build the FEPA model.As showed in Figure9, the loss function value MSE = 0.408040 is calculated, where the horizontal coordinate is time, the vertical coordinate is the daily minimum price, red represents the true value, and yellow represents the predicted value. The comparison between the predicted and true values shows that although the FEPA-EMD model can fit the trend of change and the predicted curve can better approximate the true value, there are some regions with large deviations, and the predicted data are both higher and lower than the true data, and the loss function value is larger than the long-term prediction, and the overall fitting effect is relatively poor.Figure 9
Prediction accuracy of FEPA model overtime.It can be seen that the overall downward trend of the price is slow in the initial stage, followed by a rapid rise and then a rapid decline, and finally a slow downtrend, the overall trend oscillation, the initial judgment is not a smooth series. Thep value of the nonstationary series in the test result hypothesis is 0.5451, which is considerably greater than 0.05; therefore, the original hypothesis cannot be rejected, and the original series is judged to be nonstationary. Facing the nonstationary time series, the difference is often used to eliminate the smoothness and extract relevant information. The data after the difference is shown in Figure 10, the series value does not show an obvious upward or downward trend, and there is no obvious cyclical change or seasonal change; instead, it fluctuates up and down around 0, basically eliminating the trend, the data has a stable mean, and it can be determined that the first-order difference of the foreign exchange minimum price series has a smooth nature.Figure 10
First-order differential timing diagram.


## 4.1. FEPA Models for Predicting Foreign Exchange and Empirical Results

As a monetary variable of international interest, the exchange rate occupies a central position in a country’s economic system, and the stability and development of both domestic and foreign economies are affected to some extent by exchange rate fluctuations. Changes in the exchange rate reflect changes in the economic fundamentals of the international purchasing power of the local currency [25]. As the foreign exchange market is affected by various factors such as the securities market, commodity market, crude oil futures’ market, and import and export trade volume of each country, the magnitude and frequency of exchange rate fluctuations are often beyond the acceptable range of the regulatory authorities, causing a certain impact on the economy and the life of the residents of the country. Since July 2005, China has put in place a floating exchange rate system in which the RMB exchange rate will refer to a basket of currencies and be based on the market supply and demand. In November 2017, the IMF Chairman announced the addition of the RMB to the IMF’s Special Drawing Rights’ currency basket, which clears the way for the internationalization of the RMB. The US dollar, the euro, the Japanese yen, and the British pound are the current SDR basket currencies. After the RMB is added to the SDR basket of currencies, the weight of RMB in the SDR basket of currencies is 10.92%. The weight of other currencies is as follows: the weight of USD is 41.7300. The weight of the euro is 30.9300, ranking second; the weight of the yen is 8.3300, ranking fourth; the weight of the British pound is 8.0900, ranking fifth. According to the information provided by the General Administration of Customs, in the first half of 2018, the United States was our second-largest trading partner after the European Union. Since the US dollar and the euro rank first and second in the weight of the SDR basket of currencies and the EU and the US are our first and second-largest trading partners, respectively, the US dollar against the yuan and the euro against the yuan are selected as the objects of the study in this section when studying foreign exchange. The daily chart of the USD-RMB exchange rate is depicted in Figure 7. The skewness value of all samples of the USD-RMB exchange rate is greater than zero, and the kurtosis value is greater than 2, while the skewness value of all samples of the time series of the EUR-RMB exchange rate is less than zero, and the kurtosis value is greater than 3, which indicates that both the USD-RMB exchange rate and the EUR-RMB exchange rate do not obey normal distribution.Figure 7
USD/CNH daily chart.In this paper, we use the collected data for cross validation after preprocessing and split the whole training set into two parts: the training set and the validation set, while the original test set remains unchanged. Specifically, the entire training process is divided into two steps. First, the FEPA model is trained with the training set, and the hypermastigote is continuously adjusted to achieve good performance of the model in the validation set, and then, the model with confirmed hypermastigote is trained again to minimize the global error between the predicted data and the actual target of the FEPA model by modifying the weights, and finally, the test set is used for prediction and comparison. ANN has a loop connection in the hidden state. This loop constraint can ensure that the sequence information is captured in the input data. The building block of CNN is the filter, which is the kernel. The function of the kernel is to extract relevant features from the input using convolution operations. We can try to understand the importance of using images as input data filters. This article uses the ANN model.As shown in the curves of actual closing prices and predicted data in Figure8, the difference between predicted and actual data is almost zero in the training set, and the distance between the predicted data curves and actual data in the test set is almost none. The FEPA model has a strong generalization ability to effectively train financial price time series to predict series volatility. Besides, Type III is more adaptive than Type I and Type II in the face of the sharp fluctuations in the curves in the test set. Linear regression of the forex price prediction closing price, respectively, corresponds to a good fit of the LSTM model prediction data.Figure 8
Prediction results obtained from the FEPA model training forex data.


## 4.2. Analysis of the Effect of the Time Factor on Forex Deep Learning Prediction Results

The establishment of the FEPA model is the first step in the establishment of the FEPA-EMD model type. Since the prediction value of the FEPA model consists of two parts, the prediction value and the residual prediction value, and the latter residual prediction value is obtained by using the output residual of the FEPA model on the training set as the FEPA training object, the fitting effect of the FEPA model will affect the fitting effect of the hybrid model. The selection of appropriate parameters and the establishment of an effective FEPA model are necessary for the successful establishment of the hybrid model. To verify whether the fitted FEPA model has good applicability, 1200 days of rolling prediction based on the true value is performed, and after each prediction of the latter day’s data, the true value of the latter day is added to the training dataset and then predicted, and the prediction result is 0.057043. Since each prediction is based on the exact value, the model can fit the changing trend of the original data, and the model is reasonably established. The model can be used to build the FEPA model.As showed in Figure9, the loss function value MSE = 0.408040 is calculated, where the horizontal coordinate is time, the vertical coordinate is the daily minimum price, red represents the true value, and yellow represents the predicted value. The comparison between the predicted and true values shows that although the FEPA-EMD model can fit the trend of change and the predicted curve can better approximate the true value, there are some regions with large deviations, and the predicted data are both higher and lower than the true data, and the loss function value is larger than the long-term prediction, and the overall fitting effect is relatively poor.Figure 9
Prediction accuracy of FEPA model overtime.It can be seen that the overall downward trend of the price is slow in the initial stage, followed by a rapid rise and then a rapid decline, and finally a slow downtrend, the overall trend oscillation, the initial judgment is not a smooth series. Thep value of the nonstationary series in the test result hypothesis is 0.5451, which is considerably greater than 0.05; therefore, the original hypothesis cannot be rejected, and the original series is judged to be nonstationary. Facing the nonstationary time series, the difference is often used to eliminate the smoothness and extract relevant information. The data after the difference is shown in Figure 10, the series value does not show an obvious upward or downward trend, and there is no obvious cyclical change or seasonal change; instead, it fluctuates up and down around 0, basically eliminating the trend, the data has a stable mean, and it can be determined that the first-order difference of the foreign exchange minimum price series has a smooth nature.Figure 10
First-order differential timing diagram.


## 5. Conclusion

In this paper, we propose a FEPA model of deep fractional-neural network paradigm for financial market forecasting. The model consists of three parts; the first part of the financial time-series empirical modal decomposition of financial time series data is decomposed to generate multilayer IMF time series; the set of IMF series is transformed by principal component analysis for dimensionality reduction, and then, an artificial neural network model is built for forecasting. Finally, the prediction output of the artificial neural network is combined to produce the total prediction value. In this paper, this generalized FEPA model is specified as a forecasting model for the CSI 300 stock Index, Australian stock index, and foreign exchange rate and empirically validated with historical data. The empirical results demonstrate the feasibility and effectiveness of the FEPA model for several specific markets. This paper also extends this FEPA model to an interval EMD model, which also achieves better forecasting results.For nonlinear, nonstationary, multiscale financial time series, the FEPA model proposed in this paper combines the forward-rolling EMD decomposition method, principal component analysis, and neural network to give maximum play to the idea of decomposition-reconstruction integration. The authors use a rolling window with appropriate window width to extract data, and perform EMD decomposition on each extracted data, arrange all IMF components into a matrix and then use principal component analysis to reduce the dimensionality, extract all the principal components that can represent the original information, and input them into the neural network to get the prediction value. In this paper, CSI 300 Index and Australian stock index are two exchange rates selected as the test data, and the empirical results show that the EMD decomposition algorithm can effectively improve the prediction performance and the principal component analysis can compress the redundant data, shorten the training time, and can improve the prediction performance to some extent. The FEPA model improves the prediction performance to some extent than the EMD-BPNN model. The EMD-BPNN model, in turn, obtained better prediction results than the single reference model.



---

*Source: 5560886-2021-03-19.xml*