Professional Documents
Culture Documents
Assess Deep Learning Models For Egyptian Exchange Prediction Using Nonlinear Artificial Neural Networks
Assess Deep Learning Models For Egyptian Exchange Prediction Using Nonlinear Artificial Neural Networks
https://doi.org/10.1007/s00521-020-05374-9 (0123456789().,-volV)(0123456789().
,- volV)
ORIGINAL ARTICLE
Received: 6 April 2020 / Accepted: 18 September 2020 / Published online: 26 September 2020
Ó Springer-Verlag London Ltd., part of Springer Nature 2020
Abstract
Financial analysis of the stock market using the historical data is the exigent demand in business and academia. This work
explores the efficiency of three deep learning (Dl) techniques, namely Bayesian regularization (BE), Levenberg–Marquardt
(lM), and scaled conjugate gradient (SCG), for training nonlinear autoregressive artificial neural networks (NARX) for
predicting specifically the closing price of the Egyptian Stock Exchange indices (EGX-30, EGX-30-Capped, EGX-50-
EWI, EGX-70, EGX-100, and NIlE). An empirical comparison is established among the experimented prediction models
considering all techniques for the time horizon of 1 day, 3 days, 5 days, 7 days, 5 days and 30 days in advance, applying on
all the datasets used in this study. For performance evaluation, statistical measures such as mean squared error (MSE) and
correlation R are used. From the simulation result, it can be clearly suggested that BR outperforms other models for short-
term prediction especially for 3 days ahead. On the other hand, lM generates better prediction accuracy than BR- and SCG-
based models for long-term prediction, especially for 7-day prediction.
Keywords Artificial neural networks Autoregressive Bayesian regularization Deep learning Egyptian stock market
Levenberg–Marquardt Stock price prediction
123
5966 Neural Computing and Applications (2021) 33:5965–5987
accurately [8]. This is because, in business applications, – R and mean square error (MSE) are used to measure
deep learning methods do not heavily rely on sizable past model performance.
data related to economic and behavioral assumptions, but – The accuracy rates varying depending on the type of
deduce high-level features automatically. algorithm and the type of data on which the model was
Therefore, there is growing interest in applying deep trained lM and BR have equal number of times when
learning methods in finance domain, and literature shows the error is minimum, whereas lM performs well on
varying degrees of success in this regard. Since perfor- EGX-30, EGX-50-EWI, EGX-70 indices when time
mance of the deep learning network is largely dependent on period is equal to 5, 5, 3 day(s), respectively. BR
the training methods, an appropriate training mechanism is achieves minimum error on EGX-30-Capped, EGX-
important to be adopted [9]. In this regard, unlike con- 100,NIlE indices when time period is equal to 3, 1, 1
ventional neural network models, nonlinear autoregressive day(s), respectively.
with exogenous (NARX) multivariate input is more suit- – Simulation study with new real data from the Egypt
able for nonlinear systems or time-series data like stock Exchange (EGX-30, EGX-30-Capped, EGX-50-EWI,
market prices, because of exogenous inputs generated EGX-70, EGX-100, and NIlE) indices exhibits that the
externally using network feedback as in recurrent neural proposed NARX model offers superior performance for
networks (RNN). This ability of NARX makes learning both short- and long-term predictions.
better than other feed-forward neural networks and enables The paper is set out as follows: Sect. 2 reviews previous
it converge comparatively faster with better generalization research in the similar domain. Section 3 deals with basic
[10]. principles of NARX, BR, lM, and SCG algorithms. The
An array of practical applications found in the literature proposed model framework and configurations are
suggests that NARX has demonstrated potential approxi- explained in Sect. 4. Section 5 includes data description,
mation ability for highly nonlinear systems in prediction evaluation criteria used to measure accuracy and results
domain. For instance, groundwater prediction [11], photo- analysis and discussion. Finally, the conclusion is drawn in
voltaic power production prediction [12], indoor tempera- Sect. 6.
ture prediction [13], driver fatigue prediction [14],
riverbank erosion rate prediction [15], cloud datacenter
workload forecasting [16] are few promising applications 2 Literature review
to be listed. Specifically, NARX-based models for stock
markets are also put forward by Yu and Yan [17], Das et al. Neural networks (NNs) are the promising technology used
[18], Matkovskyy and Bouraoui [19], etc. Though, until by numerous researchers for developing multiple predic-
recently, there is a considerable gap, or in other words, tion models, particularly in the field of financial analysis.
demand for building more efficient NARX-based predict- For future stock price prediction, backpropagation neural
ing models for stock price prediction, specially focusing on networks (BPNN), recurrent neural networks (RNN), long
training methodologies, is realized. In the existing research, shorter-term memory (lSTM), etc., have been effectively
the academic researchers have proposed different algo- used by research community with the provision for the next
rithms such as Bayesian regularization (BR), Levenberg– day to be forecasted from a day to a month. In this section,
Marquardt (lM), and scaled conjugate gradient (SCG) for some of the important works related to stock market pre-
NARX training. diction presented recently are reported.
The sufficient ability of NARX in prediction problems While considering deep learning methods, there is still
in the existing research motivates this study to implement significant gap in the domain of stock market prediction,
the network for predicting stock prices for The Egyptian even though there has been resurgence of interest in this
Exchange (EGX). The learning efficiency of the training area. A brief literature outlook suggests that not much work
algorithms BR, lM, and SCG is evaluated on real-world has been performed by the relevant research community in
dataset. The contributions of this study to the existing lit- this field, and only a few works can be found. For example,
erature are summarized as follows: Yu and Yan [17] addressed the stock price prediction
– Nonlinear autoregressive neural network with exoge- problem keeping in view several stock indices around the
nous (NARX) inputs trained by three different algo- world, including S&P 500, Nikkei 225, and ChiNext
rithms, namely Bayesian regularization (BR), obtained from the relevant sources. The researchers used
Levenberg–Marquardt (lM), and scaled conjugate gra- deep NN with lSTM which demonstrated better overall
dient (SCG), is proposed to predict close price, for both prediction accuracy, MSE, MAPE, and correlation coeffi-
short-term (1, 3, and 5) day(s) and long-term (7, 15, and cients as compared to ARIMA, deep multilayer percep-
30 ) day(s) prediction. tions, and others. In a separate study, Araújo at al. [20]
123
Neural Computing and Applications (2021) 33:5965–5987 5967
[17] 2019 S&P 500, DJIA, N225, 2008–2017 Close price DA%, MRSE, MAPE, DNN, lSTM
ChiNext, HIS, CSI300 2010–2017 R
[20] 2019 CAC, DAX, DJIA, HS, IBOV 2013–2017 Close price AVR, MAPE, MSE, DIDlP
MER, NASDAQ, NK, NYSE POCID, THEIl
[24] 2019 EREGl, ECIlC, AFYON 2013–2015 Stock price MAPE, MAE, RMSE, HS-NN, HS-JRNN, HS-ElM
TheilU, DS HS-RElM, HS-GlM, HS-RT, HS-
GPR
[25] 2019 Reliance Private limited 2017–2018 Stock price MSE, MAPE ANN
[32] 2019 S&P 500, AAPl, TSlA, Close price MSE RNN-lSTM
GOOG
[33] 2019 Dhaka stock exchange (DSE) Close price MSE, RMSE, MACD RNN, lSTM, GRU, ARIMA
[34] 2019 SPDR S&P 500 ETF Trust 2016–2017 Stock price RMSE, RMAE, MAPE lSTM, CNN
(SPY)
[35] 2019 Guangdong enterprises- 2014–2016 Stock price MSE BPNN
Shenzhen
[36] 2019 NSE, India 2009–2018 Open price MAE, RMSE RNN-lSTM
[19] 2018 Tunisia Stock 2000–2014 IFS MSE, R NARX
[27] 2018 Casablanca Stock Close price MSE RNN-PCA, RNN
[37] 2018 BSE, NSE Open price MSE ANN
[38] 2018 KOSPI200, S&P 500 2000–2017 Close price MSE, MAPE, MAE lSTM
[39] 2018 Crystal Technology, Ming 2006–2016 Close price MSE, DA ElSTM, AElSTM
Shares
[40] 2018 S&P 500, DJIA 2010–2017 Open price Hit ratio ISCA-BPNN
[41] 2018 NSE 1996–2017 Close price MAPE MlP, RNN, lSTM, CNN
NYSE 2011–2016
[42] 2018 HIS, DAX, S&P 500 1991–2017 Close price Accuracy GRU
[43] 2018 S&P BSEBANKEX 2005–2017 Close price RMSE, DA, MdAPE lSTM, GRU, CNN, ElM
[21] 2017 Korean stock 2010–2014 Stock price NMSE, RMSE, MAE, DNN, ANN, AR, AR-DNN, DNN-
MI AR
[22] 2017 BSE, DJIA, NASDAQ, FTSE 2000–2014 Close price Average, STD ACRNN
TAIEX, S&P 500, lSE Min, Max, POCID
[23] 2017 USD to (JPY, GBP, EUR, Volatility MSE, Dstat PSO-QRNN
INR),
S&P 500 and NSE TheilU
[28] 2017 S&P 500 Index ETF (SPY) 2003–2013 Closing MSE, confusion matrix ANN-PCA, ANN-FRPCA, ANN-
price KPCA
[26] 2016 NASDAQ 1 : 6–2015 Stock price MSE, RSquare BPNN
[44] 2016 The Nikkei 225—Tokyo 1993–2013 Stock price MSE BPNN
Stock
argued that traditional NN techniques fail to produce effi- learning NN turned out to be promising tool for predicting
cient financial prediction results due to limitations when Korean KOSPI stock market.
applied on daily frequency forecast. To address the issue, Apart from deep learning approach, the researchers in
the authors presented a deep NN with each layer composed the area of stock market have utilized ANN methods
of increasing–decreasing–linear processing neurons. The trained or optimized by metaheuristic algorithms. In this
efficacy of the presented model was validated on 12 dif- context, Nayak et al. [22] trained NN by artificial chemical
ferent stock market datasets, against some of the recently reaction optimization (ACRO), hence named ACRNN, and
introduced predictive techniques reported in the literature. applied it on seven different stock indices inclusive of
In another comprehensive study by Chong et al. [21], deep NASDAQ and S&P with three difference prediction
123
5968 Neural Computing and Applications (2021) 33:5965–5987
scenarios of short term, medium term, and long term. The prediction model design, and conditions affect prediction
closing price prediction accuracy of the designed ACRNN accuracy.
was found better than multilayer perceptions, because the There is evidenced limited research where lM, SCG, or
integration of ACRO for weight and bias optimization BR algorithms have been utilized for the training of ANN-
instead of gradient-based learning proved to be promising based models; for example, Selvamuthu et al. [25] pro-
training approach. In a different work, a quantile regression posed such methodology for predicting Indian stock mar-
NN (QRNN) was trained by particle swarm optimization ket. The model performances were measured using use
(PSO), so-called PSOQRNN, by Dadabada and Vadlamani MSE, mean absolute percentage error (MAPE). The study
[23] for closing prices of S&P 500 and NSE Indian Stock contended to have achieved accuracy up to 99.9% using
Index. According to the findings, the authors claimed that tick data. Moghaddam et al. [26] also managed to train
the proposed method outperformed statistical and NN- ANN with lM for improved prediction results of daily
based methods like MlP and QRNN. likewise, [24] stock exchange rates of NASDAQ index.
deployed a variety of NN models, tuned by harmony search A combination of principal component analysis (PCA)
(HS) algorithm, for finding the most suitable model and ANN has also been duly formulated in the existing
architecture while predicting stock price for 1, 2, 3, 5, 7, research where the prior method is used for feature
and 10 day(s) ahead. The study was conducted by devel- reduction and the latter for prediction. For example, Ber-
oping different prediction systems including HS-NN, HS- radi and lazaar [27] applied this said synthesis on Total
RNN, HS-ElM (extreme learning machine), and others. Maroc from Casablanca stock exchange, and Zhong and
The researchers claimed usefulness of the study in terms of Enke [28] used the approach for daily market prediction
multiple important factors like comprehension on with 36 datasets. An effective integration of different
123
Neural Computing and Applications (2021) 33:5965–5987 5969
machine learning algorithms was also found by Patel et al. in the case of predicting time series or nonlinear problems
[29] who developed a fusion of SVM, ANN, and random [46]. The architecture of NARX provides limited feedback
forest (RF) for predicting stock prices for the indices of from the output layers instead of hidden layers. Figure 1
CNX Nifty and S&P Bombay Stock Exchange (BSE) illustrates NARX architecture. The RNN is useful because
Sensex from Indian stock markets. maintains reasoning about previous events in a task for
Hushani [30] compared the performance of statistical informing latter. Because it is a network with inbuilt loops
and NN-based methods and found that NARX provided within its layers, it allows to retain the information.
more accurate results than ARIMA, VAR (vector autore- Specifically, NARX is designed to build time-series pre-
gression), and lSTM while predicting NASDAQ closing diction models with better predictions capability than the
prices. A similar approach is found in [31] where NARX general NN models with fuðnÞ; uðn 1Þ; . . .g as inputs to
trained by lM was used to predict closing stock prices. For get fyðn þ 1Þ; yðnÞ; . . .g as outputs, as it employs the
effective training, the authors used three inputs: stock additional information contained in the series of interest
price, its highest, and the lowest price. fyðn þ 1Þ; yðnÞ; . . .g that has already been output at time
From limited literature survey, it seems that NARX with step n, and both the basic and unrolled structures of a
applications related to stock price prediction has not been general NARX as an update and improvement to a general
much witnessed in profound publishing venues. Therefore, RNN. Since a general NARX nonlinearly predicts future
it can be assumed that there is a need for finding more values fyðn þ 1Þg of a time series fyðn þ 1Þ; yðnÞ; . . .g
authentic results using NARX methodology in the sub- from not only past values of that time series but also past
jected domain. In this context, Table 1 shows summary of values of a second time series fuðn 1Þ; uðn 2Þ; . . .g. It
some recent studies for stock price prediction, to verify the then also considers updating and improving the classic
argument put forward. The first column refers to authors, autoregressive (AR) model which specifies that the output
the second column is the year of publication, the third variable fyðn þ 1Þg depends linearly on its own previous
column shows datasets used in the experiments, the forth values fyðn þ 1Þ; yðnÞ; . . .g and on a stochastic term (an
column shows the duration for data, the fifth column shows imperfectly predictable term). This justifies why this form
reports target from modeling, and the six column shows of prediction is called nonlinear autoregressive with
measures and metric used to evaluate model performance, exogenous (external) input or NARX.
whereas the last column refers to the proposed techniques. Let us assume an RNN with single input and output,
The studies are group based on the proposed model. From described by Eqs. (1) and (2). It can be equivalently
Table 1, we can see that the prediction of close price is the modeled with a representation of the neural network as:
most common target and MSE is the most common eval- xðn þ 1Þ ¼ /½Wa xðnÞ þ wb uðnÞ ð1Þ
uation metric. Therefore, in our study, we focus on pre-
T
dicting close price, and using MSE, and R as evaluation y ð nÞ ¼ c x ð nÞ ð2Þ
metric. Moreover, a NARX model trained by means of
Levenberg–Marquardt algorithm was chosen, as the exist- Using Eqs. (1) and (2), it can be easily said that the output
ing studies reveal that the NARX models are suitable for yðn þ qÞ is expressed in terms of the state xðnÞ and the
performing short time-series composite indexes prediction. input vector uq ðnÞ as:
yðn þ qÞ ¼ U xðnÞ; uq ðnÞ ð3Þ
3 Materials and methods where q is the dimensional form of the model and
U : Rq ! R. Since the recurrent network is observable,
This section provides an explanation of nonlinear autore- the local observability theorem can be written as:
gressive neural network with exogenous (NARX) input
xðnÞ ¼ W yp ðnÞ; uq1 ðnÞ ð4Þ
model architecture, and its training algorithms such as
Bayesian regularization (BR), Levenberg–Marquardt (lM), where W : Rq ! R: Hence, substituting Eq. (3) in
and scaled conjugate gradient (SCCG), as these algorithms Eq. (4), it is obtained as:
are able to generate lower mean squared error than the
yðn þ qÞ ¼ U W yp ðnÞ; uq1 ðnÞ ; uq ðnÞ
gradient-based learning methods. ð5Þ
¼ F yq ðnÞ; uq ðnÞ
3.1 Nonlinear autoregressive neural network where uq1 ðnÞ is contained in uq ðnÞ as its first elements
with exogenous (NARX) input ðq 1Þ, and the nonlinear mapping F : Rq ! R takes care
of both / and W.
NARX is a type of recurrent neural network (RNN) with
one or more feedback loops [45], and it outperforms RNN
123
5970 Neural Computing and Applications (2021) 33:5965–5987
123
Neural Computing and Applications (2021) 33:5965–5987 5971
123
5972 Neural Computing and Applications (2021) 33:5965–5987
5 Experimental results
Table 4 Description of used parameters
Parameter Description 5.1 Data description
Open price The price in the beginning of daily dealing
This study is based on the historical data for some of the
High price The highest price reached by the end of daily dealing
indicators on the Egyptian Stock Exchange (EGX), in order
low price The lowest price reached by the end of daily dealing to build a prediction model with high accuracy. Data used
Close price The price in the end of daily dealing in this study are purchased from Egypt for Information
Dissemination (EGID)1 which is a Governmental organi-
zation that provides data for EGX. The data contain six
that from 6–14, 16–19, and 21–25 neurons generate similar stock market indices; for example, EGX-30 index local
accuracy. In the mentioned study, when they used 15 currency is used for interest estimates and denominated in
neurons, the accuracy decreased; in the case of 19–23, US dollars. It measures top 30 firms in liquidity and
accuracy slightly increased. Hence, the architecture with activity. The second index used in this study is EGX-30-
3–6–1 with three inputs, a hidden layer with six neurons Capped which is designed to track performance of the most
including bias, and an output reduces the training and traded companies in accordance with the rules set for
model approximation cost. For delay, we carried out dif- mutual funds. The third index is EGX-70 which aims at
ferent prediction time horizons such as 1 day, 3 days, 5 providing wider tools for investors to monitor market
days, 7 days, 15 days, and 30 days performance. EGX-100 index as a forth dataset evaluates
The third step is selection of the training algorithm. In performance of the 100 active firms, including 30 of EGX-
this study, Bayesian regularization (BR), Levenberg–Mar- 30 index as well as 70 of EGX-70 index. NIlE index avoids
quardt (lM), and scaled conjugate gradient (SCG) are used concentration on one industry and therefore has a good
to train the NARX network. The orange dashed line pre- representation of various industries/sectors in the economy,
sents training data, and the blue dashed line represents and the index is weighted by market capitalization and
validation data. BR uses validation data with training data adjusted by free float. The last index is EGX-50-EWI
to train the model. The fourth step is to test model by which tracks top 50 companies in terms of liquidity and
performing prediction on the test set and evaluate model activity. The index is designed to balance the impact of
accuracy using MSE and correlation coefficient R. In order price changes among the constituents of the index as they
to ensure model accuracy, training and validation data are will have a fixed weight of 2% at each quarterly review.
used with test data in order to test and evaluate the model. The historical period of data in the study starts from
The green line in Fig. 1 presents test data, the orange line EGID registration of these data to date August 27, 20192 as
presents training data, and the blue line denotes validation shown in Table 3. The data contain eight features: code,
data. The last step is to compare prediction results if it is date, open price, high price, low price, close price, volume,
acceptable so the task ends; otherwise, return to step 2 and and value. This study uses open price, high price, and low
modify the NARX architecture. The parameter settings of price as input features, and close price as target feature, as
used techniques are reported in Table 2. shown in Table 4.
1
www.egidegypt.com.
2
www.egx.com.eg.
123
Neural Computing and Applications (2021) 33:5965–5987 5973
100
99.96
99.94 98
99.92
96
99.9
Accuracy
Accuracy
99.88 94
99.86
92
99.84
99.82 90
99.8
88
99.78
BR LM SCG BR LM SCG
Algorithms Algorithms
(a) Boxplot on EGX-30. (b) Boxplot on EGX-30-Capped.
99.9
99.94
99.92 99.8
99.9
99.7
99.88
Accuracy
Accuracy
99.6
99.86
99.84 99.5
99.82
99.4
99.8
99.3
99.78
BR LM SCG BR LM SCG
Algorithms Algorithms
(c) Boxplot on EGX-50-EWI. (d) Boxplot on EGX-70.
99.98
99.96 99.9
99.94
99.85
99.92
99.9 99.8
Accuracy
Accuracy
99.88
99.75
99.86
99.7
99.84
99.82
99.65
99.8
99.6
99.78
BR LM SCG BR LM SCG
Algorithms Algorithms
(e) Boxplot on EGX-100. (f) Boxplot on NIlE.
Fig. 3 Boxplot for 1-, 3-, 5-, 7-, 15-, 30-day-ahead prediction based on data and training algorithms
123
5974 Neural Computing and Applications (2021) 33:5965–5987
(a) MSE on EGX-30. (b) MSE on EGX-30-Capped. where y is the actual value and y is the predicted value.
– Regression R value (Pearson correlation coefficient)
BR LM SCG BR LM SCG measures the correlation between actual and the
1 day 1 day
0.00035 0.00100 predicted prices as expressed in Eq. (16):
0.00030
0.00025
0.00080 Pn
30 days 0.00020 3 days 30 days
0.00060
3 days t¼1 ðyt yt Þðyt yt Þ
0.00015 0.00040 R ¼ qffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffi
Pn ffi ð16Þ
0.00010 2 2
0.00005
0.00000
0.00020
0.00000
ð
t¼1 t
y y t Þ ðyt y t Þ
15 days 5 days 15 days 5 days where yt is the actual price and yt is the predicted price
[17].
7 days 7 days It is important to note that the lower the MSE and the
(c) MSE on EGX-50-EWI. (d) MSE on EGX-70. closer to 1 is R, the more reliable are the prediction results.
BR LM SCG BR LM SCG
1 day 1 day 5.4 Results analysis
0.00030 0.00035
0.00025 0.00030
0.00020 0.00025
30 days 0.00015 3 days 30 days 0.00020
0.00015
3 days Analyzing the stock market is one of the important tasks,
0.00010
0.00005
0.00010
0.00005
where many methods have been proposed by the
0.00000 0.00000
researchers to predict stock price with the expectations of
15 days 5 days 15 days 5 days
getting predicted results closer to the actual value. The
experimental design includes two main factors: forecast
7 days 7 days
time horizon and the training algorithm. We obtained 108
(e) MSE on EGX-100. (f) MSE on NIlE. individual prediction results: across six financial markets
(EGX-30, EGX-30-Capped, EGX-50-EWI, EGX-70, EGX-
Fig. 4 MSE Comparison for 1-, 3-, 5-, 7-, 15-, 30-day-ahead 100, and NIlE) 6 forecast time horizons 3 model
prediction based on data and training algorithms using radar chart specifications (BR, lM, and SCG). Each dataset was divi-
ded into training, validation, and testing sets with the ratio
5.2 Data preprocessing of 70:15:15. The results enabled us to compare the fore-
casting accuracy across different time intervals. The
According to Demuth et al. [56], it is often helpful for the experiments were carried out on a PC with Intel Core i7-
training algorithms to perform well when the inputs and the 7500 CPU 2.70 GHz, 12 GB RAM, Windows 10, and
target values are scaled in the range of ½1; 1. Following MATLAB 2016b. This section is divided into two sub-
the argument for the enhanced prediction results, we nor- sections: first, we report short-term predictions (1 day, 3
malized our data using minimum scale function [57], as days, and 5-days) followed by the long-term predictions (7
Eq. (14): days, 15 days, and 30 days). In order to curb paper length,
we report only the best results with fair comparison.
xi minðxÞ
x^i ¼ ; i 2 ½1; 2; . . .; n ð14Þ Figure 3 displays the distribution of model accuracy,
maxðxÞ minðxÞ
using the box plots, across all time horizons among dif-
where x^i is a normalized value at index i in total n samples. ferent model specifications. For EGX-30 and EGX-30-
Capped, the experimental findings reveal that BR outper-
5.3 Evaluation metrics formed lM and SCG (Fig. 3a), while lM gave best results
on rest of the datasets. The results show that BR outper-
The following measures are used to validate and evaluate formed other models by average accuracy of 99.96% and
the proposed approach: 99.32% for EGX-30 and EGX-30-Capped, respectively. On
the other hand, the average accuracy produced by lM
123
Neural Computing and Applications (2021) 33:5965–5987 5975
ACCURACY
99.91200% 99.91680%
99.88%
99.85%
99.82%
99.79%
99.76%
99.74760%
99.73%
1 3 5 7 15 30
DAYS
(a) Accuracy R on EGX-30.
BR LM SCG
100.00%
98.59620% 99.09490% 98.65720% 98.72820%
97.85480% 98.30510%
98.00% 98.80510%
97.66170% 97.34790%
97.20340%
96.00% 97.85850% 97.89390%
96.62380% 96.76850%
ACCURACY
94.00%
94.64870%
95.06190%
90.32050%
92.00%
90.00%
88.00% 87.25750%
86.00%
1 3 5 7 15 30
DAYS
(b) Accuracy R on EGX-30-Capped.
remained 99.92%, 99.85%, 99.95% and 99.89% for EGX- From Fig. 5a and b, we can see that the short-term accu-
50-EWI, EGX-70, EGX-100 and NIlE, respectively. It can racy increased by increasing the prediction period and
be inferred from the findings that the lM algorithm was decreased by increasing the prediction time period for the
more accurate as compared to BR. Overall, lM and BR long term. Figure 7b reveals that, in general, accuracy
were able to obtain lower mean squared errors than SCG. decreased by increasing prediction period for the two long-
For prediction accuracy, Figs. 5, 6, and 7 show accuracy and short-term predictions.
distribution based on datasets, where y-axis refers to In addition, we use radar charts representing MSE across
accuracy and the x-axis is the prediction time horizon. all time horizons among different models, using Fig. 4
123
5976 Neural Computing and Applications (2021) 33:5965–5987
ACCURACY
99.91540% 99.90610% 99.91370%
99.91450%
99.88%
99.91310% 99.86260%
99.87180% 99.87450% 99.88760%
99.85%
99.82%
99.79% 99.79420%
99.77790%
99.76%
1 3 5 7 15 30
DAYS
BR LM SCG
100.00%
99.88050%
99.86260% 99.86340%
99.90% 99.83070% 99.86040% 99.82340%
99.87080% 99.80640%
99.80%
99.84100% 99.80780% 99.73910%
99.82040%
99.80010%
99.70% 99.74290% 99.74940%
ACCURACY
99.72050%
99.71410%
99.60%
99.50%
99.40%
99.30%
99.27050%
99.20%
1 3 5 7 15 30
DAYS
where the errors of all the selected models for each dataset when compared with other methods for most of the time
are summarized. Here, it is easy to infer that SCG produced horizons.
worst results for all time horizons, as the radar lines of the
counterparts are surrounded by the SCG line for most of 5.4.1 Short-term prediction
the radar. In this context, BR and lM performed better on
almost all the datasets. From these analyses, it is obvious The proposed models have been adjusted to perform a
that the radar line pertaining to SCG is near the edges of short-term prediction, and most of the previous studies
the chart, indicating that SCG generated maximum value mainly focus on one-day-ahead prediction. The statistical
123
Neural Computing and Applications (2021) 33:5965–5987 5977
ACCURACY
99.92150%
99.87880%
99.87%
99.81150%
99.82%
99.78350%
99.77%
1 3 5 7 15 30
DAYS
(a) Accuracy R on EGX-100.
BR LM SCG
99.98%
99.92880%
99.88940% 99.89970%
99.93%
99.89450%
99.92670% 99.88070%
99.88% 99.86530%
99.85120%
99.88930%
99.88570% 99.83190%
ACCURACY
99.83% 99.81010%
99.88860%
99.76900%
99.78%
99.75600% 99.74170%
99.70700%
99.73%
99.68%
99.63% 99.59380%
99.58%
1 3 5 7 15 30
DAYS
measures reported in this section show that efficient results efficient results, we calculated total error on all datasets for
have been achieved by all the training algorithms, see the time period of 3 days which are 5:19924 104 and
Figs. 5, 6, and 7. As can be seen in Figs. 5a and 6a, lM 5:4693 104 for BR and lM, respectively. Conclusively,
with time period of 5 days outperformed other algorithms. BR obtained minimum total error.
Also, lM achieved better results according for time period From the analysis performed in this section, it can be
of 3-days, see Fig. 6b. BR also performed better as clearly suggested that the performance of BR algorithm in
observed in Figs. 5b and 7a with time period 3 days and for predicting the above-mentioned stock indices outperformed
1 day (Fig. 7b). Since BR and lM generated equally SCG and lM. The simulated graph of EGX-30, EGX-30-
123
5978 Neural Computing and Applications (2021) 33:5965–5987
Table 5 Short-term MSE results for test data based on index and prediction periods
Prediction period Algorithm MSE 104 on test set
EGX-30 EGX-30-Capped EGX-50-EWI EGX-70 EGX-100 NIlE
Table 6 Short-term accuracy (R) for test data based on index and prediction periods
Prediction period Algorithm Accuracy R (in %)
EGX-30 EGX-30-Capped EGX-50-EWI EGX-70 EGX-100 NIlE
Capped, EGX-50-EWI, EGX-70, EGX-100 and NIlE data from the results, BR attained considerably better results
considers 3 days ahead to be predicted, as depicted in Fig. than all the comparison models associated with the three
8 where BR technique was set for training NARX and used methods. As shown in Table 6, the best regression value
stock data as input to the prediction model. In the experi- R of NARX model is grater or equal to 99.9% for testing
mental outcome, some of the simulated graphs of actual datasets, which is about 100%.
versus the predicted are shown in this paper to limit the The actual versus predicted graph of all the experi-
paper length; though, a comprehensive understanding can mented datasets using BR algorithm for 3-day-ahead
be achieved from Tables 5 and 6 showing MSE and pre- closing price is depicted in Fig. 8 showing the prediction
diction accuracy. These findings can be supported by the curves generated. The curve of predicted values is located
research performed in Orimoloye et al. [58] which suggests closest to the actual curve in all the six figures, suggesting
that the ANN network trained by BR is relatively expected that the proposed method attained more outstanding overall
to produce efficient prediction results as compared to the performances. Overall, these results illustrate the efficiency
one trained by lM. of BR as a viable mechanism for prediction.
Tables 5 and 6 summarize MSE and accuracy R in The regression plot shows actual versus predicted graph
percentage (%) for three proposed models on test data of of all the experimented datasets using BR algorithm for
different datasets. The tables show the experimental results 3-day-ahead closing price in Fig. 9 which measures cor-
for BR, lM and SCG methods for all time periods. The first relation between prediction and actual values. The blue
column shows prediction period and the second column rings refer to predicted, red to actual value and dashed line
refers to the training algorithm used, while the rest of the to fit. As shown is high coloration between predicted and
columns refer to datasets. Table 5 presents normalized the actual on all the six figures. It is important to note from
values of actual MSE ¼ Presented 104 . As can be seen these results that regression value R is close to 100%.
123
Neural Computing and Applications (2021) 33:5965–5987 5979
Close Price Prediction of EGX 30 using BR Close Price Prediction of EGX 30 Capped using BR
1.2 1.2
Actual Predicted Actual Predicted
1 1.15
0.8 1.1
Close Price
Close Price
1.05
0.6
1
0.4
0.95
0.2
0.9
0 0.85
0 20 40 60 80 100 120 140 160 180 200 220 240 260 280 300 320 340 360 380 400
0 2 4 6 8 10 12 14 16 18 20
Days Days
(a) Predictionon EGX-30. (b) Predictionon EGX-30-Capped.
Close Price Prediction of EGX 70 using BR
1.2
Close Price Prediction of EGX 50 EWI using BR 1.2
Actual Predicted
Actual Predicted
1 1
Close Price
0.8
Close Price
0.8
0.6 0.6
0.4 0.4
0.2 0.2
0 0
0 20 40 60 80 100 120 140 150 0 20 40 60 80 100 120 140 160 180 200 220 240 260 280 300 320 340 360 380 400
Days Days
Actual Predicted
1 1 Actual Predicted
Close Price
0.8
Close Price
0.8
0.6 0.6
0.4 0.4
0.2 0.2
0 0
0 20 40 60 80 100 120 140 160 180 200 220 240 260 280 300 320 340 360 380 400 0 20 40 60 80 100 120 140 160 180 200 220 240 250
Days Days
(e) Predictionon EGX-100. (f) Predictionon NIlE.
Fig. 8 Three-day-ahead prediction for all datasets using BR training algorithm; blue curve represents predicted values, whereas red curve
represents the actual values. The curves show that the model gives predicted values close to the actual ones for all datasets (color figure online)
5.4.2 Long-term prediction depicted for all the models in Figs. 5a and 6a. Here, BR
with the time period of 7 days outperformed other algo-
The proposed model was also adjusted to perform a long- rithms and SCG achieved better results according to
term prediction, as it has the same importance for investors. Fig. 5b for the time period of 30 days. lM performed well
The statistical measures show the efficient results, as as seen in Figs. 6b and 7a with the time period of 7 days,
123
5980 Neural Computing and Applications (2021) 33:5965–5987
R=0.9995 R=0.98596
1 1
Actual Fit Predicted
Predicted ~= 1*Actual + 0.00055
Actual Fit Predicted
0.8
0.7
0.95
0.6
0.5
0.4
0.9
0.3
0.2
0.1
0 0.85
0 0.2 0.4 0.6 0.8 1 0.85 0.9 0.95 1
Actual Actual
(a) Correlation Coefficient R on EGX-30. (b) Correlation Coefficient R on EGX-30-Capped.
R=0.99915 R=0.99871
Predicted ~= 0.99*Actual + 0.0031
0.8 0.8
0.7 0.7
0.6 0.6
0.5 0.5
0.4 0.4
0.3 0.3
0.2 0.2
0.1 0.1
0
0 0.2 0.4 0.6 0.8 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9
Actual Actual
(c) Correlation Coefficient R on EGX-50-EWI. (d) Correlation Coefficient R on EGX-70.
R=0.99963 R=0.99889
0.9 0.9
Predicted ~= 1*Actual + -0.001
0.8 0.8
0.7 0.7
0.6 0.6
0.5 0.5
0.4 0.4
0.3 0.3
0.2 0.2
0.1 0.1
0
0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 0 0.2 0.4 0.6 0.8
Actual Actual
(e) Correlation Coefficient R on EGX-100. (f) Correlation Coefficient R on NIlE.
123
Neural Computing and Applications (2021) 33:5965–5987 5981
b Fig. 9 Three-day-ahead correlation coefficient (R); regression plots results, the regression values shown here are also close to
provide a clear vision about model accuracy R and how prediction is 100%.
close to actual. Figure shows that the fit is very good for all datasets.
Most of the R values are equal to 0.99 or above, except for EGX-30-
Capped, which gives R value equal to 0.98; therefore, prediction
accuracy is high
5.5 Comparison with state of the art
123
5982 Neural Computing and Applications (2021) 33:5965–5987
Close Price Prediction of EGX 30 using LM Close Price Prediction of EGX 30 Capped using LM
1.2
1.2
1.1
Close Price
0.8
Close Price
1.05
0.6
1
0.4
0.95
0.2 0.9
0.85
0 0 2 4 6 8 10 12 14 16 18 20
0 20 40 60 80 100 120 140 160 180 200 220 240 260 280 300 320 340 360 380 400
Days Days
(a) Prediction on EGX-30. (b) Prediction on EGX-30-Capped.
1.2
Close Price Prediction of EGX 50 EWI using LM Close Price Prediction of EGX 70 using LM
1.2
0.8
Close Price 0.8
0.6
0.6
0.4
0.4
0.2
0.2
0
0 20 40 60 80 100 120 140 150 0
0 20 40 60 80 100 120 140 160 180 200 220 240 260 280 300 320 340 360 380 400
Days
Days
(c) Prediction on EGX-50-EWI.
(d) Prediction on EGX-70.
Close Price Prediction of EGX 100 using LM Close Price Prediction of NILE using LM
1.2
1.2
0.8
0.8
Close Price
Close Price
0.6
0.6
0.4
0.4
0.2
0.2
0
0 20 40 60 80 100 120 140 160 180 200 220 240 260 280 300 320 340 360 380 400 0
0 20 40 60 80 100 120 140 160 180 200 220 240 250
Days Days
(e) Prediction on EGX-100. (f) Prediction on NIlE.
Fig. 10 Seven-day-ahead prediction for all datasets using lM training algorithm; blue curve represents predicted values, whereas red curve is
actual values. Figure shows that the proposed model gives predicted values close to actual values for all datasets (color figure online)
term forecast [71]. (3) NARX structure allows the learning Besides benefits, the proposed NARX also poses some
algorithm to efficiently approximate and fine-tune the limitations as discussed below: (1) The application of the
model parameters [72, 73]. (4) It has been successfully NARX is still immature under some scenarios due to the
applied to many areas as we mentioned before in Sect. 5.5. fact that there are no such general decision criteria for
123
Neural Computing and Applications (2021) 33:5965–5987 5983
Table 7 Long-term MSE for test data based on index and prediction periods
Prediction period Algorithm MSE x104 on test set
EGX-30 EGX-30-Capped EGX-50-EWI EGX-70 EGX-100 NIlE
Table 8 Long-term accuracy R for test data based on index and prediction periods
Prediction period Algorithm Accuracy R (in %)
EGX-30 EGX-30-Capped EGX-50-EWI EGX-70 EGX-100 NIlE
architecture setting for the training algorithm. (2) The most configurations in the field of stock price prediction.
favorable behavior of a specially constructed NARX model Therefore, authors recommend the proposed results to be
is dependent upon the exogenously designated time delay tested and applied to other similar nonlinear systems that
that is especially important for the initial prediction, the model other type of similar networks in the field of stock
selection of time points for training, validation, or testing price prediction which is previously mentioned in Table 9,
that may lead to either different fitting performance for the and in other different fields such as photovoltaic power
known objects during training or different prediction per- [12], social contagion [74], gas flow equation [75], and
formance for unknown objects outside of training. (3) In elasticity [76] which could provide and improve solutions
the case of too small number of neurons in the hidden for those systems.
layer, NARX may result in inappropriate generalization
ability or the chances of overfitting when dealing with
highly nonlinear dynamic mapping. This may not produce 6 Conclusion
better forecasts and perform false fitting of the known
instances in the training process. (4) In the absence of The high nonlinearity and volatility of financial time series,
specific criteria and scenario-based selection, the optimal including stock market, make prediction a paramount
determination of NARX architectural elements is a critical problem in machine learning paradigm. In this study, we
and difficult task. examined methods like BR, lM, and SCG to train the
The results of this study suggest that there is significant NARX network for predicting the return of the Egyptian
predictive accuracy which can be achieved when employ- Stock Exchange (EGX) indices (EGX-30, EGX-30-Cap-
ing the proposed NARX model with the predefined ped, EGX-50-EWI, EGX-70, EGX-100, and NIlE). We
123
5984 Neural Computing and Applications (2021) 33:5965–5987
R=0.99945 R=0.98305
1
Actual Fit Predicted Actual Fit Predicted
0.7
0.94
0.6
0.92
0.5
0.4 0.9
0.3
0.88
0.2
0.86
0.1
0.84
0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 0.84 0.86 0.88 0.9 0.92 0.94 0.96 0.98
Actual Actual
0.7 0.7
0.6 0.6
0.5 0.5
0.4 0.4
0.3 0.3
0.2 0.2
0.1 0.1
0.2 0.4 0.6 0.8 1 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9
Actual Actual
0.8
0.8
0.7 0.7
0.6 0.6
0.5 0.5
0.4 0.4
0.3 0.3
0.2 0.2
0.1 0.1
0
0 0. 2 0. 4 0. 6 0.8 0. 2 0. 4 0. 6 0. 8 1
Actual Actual
Fig. 11 Seven-day-ahead correlation coefficient (R) regression plots Most of the subfigures show R value equal to 0.99 or above, except
provide a clear vision about the model accuracy and how prediction is EGX-30-Capped, which gives R value equal to 0.98; therefore,
close to actual. Figure shows that the fit is very good for all datasets. prediction accuracy is high
123
Neural Computing and Applications (2021) 33:5965–5987 5985
Table 9 Comparative study with the state-of-the-art methods based on accuracy in average
Reference Data Technique Measure Accuracy (%) in Average
compared the prediction performance of the different Compliance with ethical standards
models developed according to the training algorithms
individually. The empirical results showed that the pro- Conflict of interest The authors declare that they have no conflict of
interest.
posed models could successfully predict the stock market
returns with slight difference in accuracy for most of the
time periods. For the BR, lM, and SCG training algorithms, References
we conducted an experiment with all datasets. We then
adjusted the parameter settings to compare with other 1. Das SR, Mishra D, Rout M (2019) Stock market prediction using
prediction models. Considering the accuracy level of BR firefly algorithm with evolutionary framework optimized feature
model, BR outperformed lM and SCG in short-term pre- reduction for oselm method. Expert Syst Appl X 4:100016
2. Jin Z, Yang Y, Liu Y (2019) Stock closing price prediction based
diction for 3-days ahead. In addition, lM achieved better on sentiment analysis and LSTM. Neural Comput Appl p 1–17
results than BR and SCG in long-term prediction for 7-days 3. Armano G, Marchesi M, Murru A (2005) A hybrid genetic-neural
ahead. In our future work, we will try to add some technical architecture for stock indexes forecasting. Inf Sci 170(1):3–33
indicators to the proposed data in order to measure the 4. Mishra S, Padhy S (2019) An efficient portfolio construction
model using stock price predicted by support vector regression.
efficiency of using technical indicators in the prediction In: The North American Journal of Economics and Finance,
process and developed model will be a hybrid approach p 101027
using recent metaheuristic algorithms for NARX network 5. Tkáč M, Verner R (2016) Artificial neural networks in business:
parameters training. two decades of research. Appl Soft Comput 38:788–804
6. Esfahanipour A, Aghamiri W (2010) Adapted neuro-fuzzy
inference system on indirect approach tsk fuzzy rule base for
Acknowledgements The authors would like to thank Minia Univer-
stock market analysis. Expert Syst Appl 37(7):4742–4748
sity for supporting this research. This research is also partially sup-
7. Sadaei HJ, Enayatifar R, lee MH, Mahmud M (2016) A hybrid
ported by University of Electronic Science and Technology of China
model based on differential fuzzy logic relationships and impe-
(UESTC) and National Natural Science Foundation of China (NSFC)
rialist competitive algorithm for stock market forecasting. Appl
under the Grant No. 61772120.
Soft Comput 40:132–149
123
5986 Neural Computing and Applications (2021) 33:5965–5987
8. Shi L, Teng Z, Wang L, Zhang Y, Binder A (2018) Deepclue: 27. Zahra B, Lazaar M (2019) Integration of principal component
visual interpretation of text-based deep stock prediction. IEEE analysis and recurrent neural network to forecast the stock price
Trans Knowl Data Eng 31(6):1094–1108 of casablanca stock exchange. Procedia Comput Sci 148:55–61
9. Bai Y, Jin X, Wang X, Su T, Kong J, Lu Y (2019) Compound 28. Zhong X, Enke D (2017) Forecasting daily stock market return
autoregressive network for prediction of multivariate time series. using dimensionality reduction. Expert Syst Appl 67:126–139
Complexity, 2019 29. Patel J, Shah S, Thakkar P, Kotecha K (2015) Predicting stock
10. Sheremetov I, Cosultchi A, Martı́nez-Muñoz J, Gonzalez-Sán- market index using fusion of machine learning techniques. Expert
chez A, Jiménez-Aquino MA (2014) Data-driven forecasting of Syst Appl 42(4):2162–2172
naturally fractured reservoirs based on nonlinear autoregressive 30. Hushani P (2019) Using autoregressive modelling and machine
neural networks with exogenous input. J Petrol Sci Eng learning for stock market prediction and trading. In: Third
123:106–119 International Congress on Information and Communication
11. Wunsch A, liesch T, Broda S (2018) Forecasting groundwater Technology, pp 767–774. Springer
levels using nonlinear autoregressive networks with exogenous 31. labde S, Patel S, Shukla M (2017) Time series regression model
input (NARX). J Hydrol 567:743–758 for prediction of closing values of the stock using an adaptive
12. louzazni M, Mosalam H, Khouya A (2020) A non-linear auto- narx neural network. Int J Comput Appl 158(10):29–35
regressive exogenous method to forecast the photovoltaic power 32. Pawar K, Jalem RS, Tiwari V (2019) Stock market price pre-
output. Sustain Energy Technol Assess 38:100670 diction using LSTM RNN. In: Emerging Trends in Expert
13. Delcroix B, le Ny J, Bernier M, Azam M, Qu B, Venne J-S Applications and Security, pp 493–503. Springer
(2020) Autoregressive neural networks with exogenous variables 33. Bhowmick A, Rahman A, Rahman RM (2019) Performance
for indoor temperature prediction in buildings. In: Building analysis of different recurrent neural network architectures and
Simulation, pp 1–14. Springer classical statistical model for financial forecasting: A case study
14. Zhou F, Alsaid A, Blommer M, Curry R, Swaminathan R, on dhaka stock exchange. In: Computer Science On-line Con-
Kochhar D, Talamonti W, Tijerina L, Lei B (2020) Driver fatigue ference, pp 277–286. Springer
transition prediction in highly automated driving using physio- 34. Kim T, Kim HY (2019) Forecasting stock prices with a feature
logical features. In: Expert Systems with Applications, p 113204 fusion lstm-cnn model using different representations of the same
15. Saadon A, Abdullah J, Muhammad NS, Ariffin J (2020) Devel- data. PloS ONE 14(2):e0212320
opment of riverbank erosion rate predictor for natural channels 35. Cao J, Wang J (2019) Exploration of stock index change pre-
using NARX-QR factorization model: a case study of Sg. Ber- diction model based on the combination of principal component
nam, Selangor, Malaysia. Neural Comput Appl pp. 1–11 analysis and artificial neural network. Soft Comput, pp 1–10
16. Kumar J, Saxena D, Singh AK, Mohan A (2020) Biphase adap- 36. Naik N, Mohan BR (2019) Study of stock return predictions using
tive learning-based neural network model for cloud datacenter recurrent neural networks with LSTM. In: International confer-
workload forecasting. Soft Comput, pp 1–18 ence on engineering applications of neural networks, pp 453–459.
17. Yu P, Yan X (2019) Stock price prediction based on deep neural Springer
networks. Neural Comput Appl, pp 1–20 37. Jadhav S, Dange B, Shikalgar S (2018) Prediction of stock market
18. Das D, Sadiq AS, Mirjalili S, Noraziah A (2017) Hybrid clus- indices by artificial neural networks using forecasting algorithms.
tering-gwo-narx neural network technique in predicting stock In: International conference on intelligent computing and appli-
price. In: Journal of Physics: Conference Series, volume 892, cations, pp 455–464. Springer
page 012018. IOP Publishing, 38. Baek Y, Kim HY (2018) Modaugnet: A new forecasting frame-
19. Matkovskyy R, Bouraoui T (2019) Application of neural net- work for stock market index value with an overfitting prevention
works to short time series composite indexes: evidence from the lstm module and a prediction lstm module. Expert Syst Appl
nonlinear autoregressive with exogenous inputs (narx) model. 113:457–480
J Quant Econ 17(2):433–446 39. Pang X, Zhou Y, Wang P, Lin W, Chang V (2018) An innovative
20. Araújo RdeA, Nedjah N, Oliveira A lI, Silvio Rdel (2019) A deep neural network approach for stock market prediction. J Super-
increasing–decreasing-linear neural network for financial time comput, pp 1–21
series prediction. Neurocomputing 347:59–81 40. Hu H, Tang L, Zhang S, Wang H (2018) Predicting the direction
21. Chong E, Han C, Park FC (2017) Deep learning networks for of stock markets using optimized neural networks with google
stock market analysis and prediction: methodology, data repre- trends. Neurocomputing 285:188–195
sentations, and case studies. Expert Syst Appl 83:187–205 41. Hiransha M, Gopalakrishnan EA, Menon VK, Soman KP (2018)
22. Nayak SC, Misra BB, Behera HS (2017) Artificial chemical Nse stock market prediction using deep-learning models. Proce-
reaction optimization of neural networks for efficient prediction dia Comput Sci 132:1351–1362
of stock market indices. Ain Shams Eng J 8(3):371–390 42. Shen G, Tan Q, Zhang H, Zeng P, Jianjun X (2018) Deep learning
23. Pradeepkumar D, Ravi V (2017) Forecasting financial time series with gated recurrent unit networks for financial sequence pre-
volatility using particle swarm optimization trained quantile dictions. Procedia Comput Sci 131:895–903
regression neural network. Appl Soft Comput 58:35–52 43. Balaji AJ, Ram DSH, Nair BB (2018) Applicability of deep
24. Göçken M, Özçalıcı M, Boru A, Dosdoğru AT (2019) Stock price learning models for stock price forecasting an empirical study on
prediction using hybrid soft computing models incorporating bankex data. Procedia Comput Sci 143:947–953
parameter tuning and input variable selection. Neural Comput 44. Qiu M, Song Y, Akagi F (2016) Application of artificial neural
Appl 31(2):577–592 network for the prediction of stock market returns: the case of the
25. Selvamuthu D, Kumar V, Mishra A (2019) Indian stock market japanese stock market. Chaos Solitons Fractals 85:1–7
prediction using artificial neural networks on tick data. Financial 45. Jin L, Li S, Hu B (2017) Rnn models for dynamic matrix
Innovat 5(1):16 inversion: a control-theoretical perspective. IEEE Trans Ind Inf
26. Moghaddam AH, Moghaddam MH, Esfandyari M (2016) Stock 14(1):189–199
market index prediction using artificial neural network. J Econ 46. Lin T-N, Giles CL, Horne BG, Kung S-Y (1997) A delay damage
Finance Admin Sci 21(41):89–93 model selection algorithm for narx neural networks. IEEE Trans
Signal Process 45(11):2719–2730
123
Neural Computing and Applications (2021) 33:5965–5987 5987
47. lipu MSH, Hannan MA, Hussain A, Saad MHM, Ayob A, 63. Tong S, Sun K, Sui S (2017) Observer-based adaptive fuzzy
Blaabjerg F (2018) State of charge estimation for lithium-ion decentralized optimal control design for strict-feedback nonlinear
battery using recurrent narx neural network model based lighting large-scale systems. IEEE Trans Fuzzy Syst 26:569–584
search algorithm. IEEE Access 6:28150–28161 64. Zhang J, Yin Z, Wang R (2017) Nonlinear dynamic classification
48. Haykin S (1994) Neural networks: a comprehensive foundation. of momentary mental workload using physiological features and
Prentice Hall PTR, Upper Saddle River NARX-model-based least-squares support vector machines. IEEE
49. Buevich A, Sergeev A, Shichkin A, Baglaeva E (2020) A two- Trans Hum–Mach Syst 47:536–549
step combined algorithm based on NARX neural network and the 65. Xiao Z, Jing X, Cheng L (2013) Parameterized convergence
subsequent prediction of the residues improves prediction accu- bounds for Volterra series expansion of NARX models. IEEE
racy of the greenhouse gases concentrations. Neural Comput Trans Signal Process 61:5026–5038
Appl 1–11 66. Feng F, He X, Wang X, Luo C, Liu Y, Chua TS (2019) Temporal
50. Møller MF (1990) A scaled conjugate gradient algorithm for fast relational ranking for stock prediction. ACM Trans Inf Syst
supervised learning. Aarhus University, Computer Science (TOIS) 37:1–30
Department 67. Zhang L, Aggarwal C, Qi G-J (2017) Stock price prediction via
51. Aburaed N, Atalla S, Mukhtar H, Al-Saad M, Mansoor W (2019) discovering multi-frequency trading patterns. In: Proceedings of
Scaled conjugate gradient neural network for optimizing indoor the 23rd ACM SIGKDD international conference on knowledge
positioning system. In: 2019 International Symposium on Net- discovery and data mining: 2141–2149
works, Computers and Communications (ISNCC), pp 1–4. IEEE 68. Kara Y, Boyacioglu MA, Baykan ÖK (2011) Predicting direction
52. MacKay DJC (1992) Bayesian interpolation. Neural Comput of stock price index movement using artificial neural networks
4(3):415–447 and support vector machines: the sample of the Istanbul Stock
53. Jonathon T (2013) A bayesian regularized artificial neural net- Exchange. Expert Syst Appl 38:5311–5319
work for stock market forecasting. Expert Syst Appl 69. Patel J, Shah S, Thakkar P, Kotecha, K (2015) Predicting stock
40:5501–5506 and stock price index movement using trend deterministic data
54. Taqvi SA, Tufa LD, Zabiri H, Maulud AS, Uddin F (2018) Fault preparation and machine learning techniques. Expert Syst Appl
detection in distillation column using NARX neural network. 42:259–268
Neural Comput Appl 1–17 70. Wang J, Wang J (2016) Forecasting energy market indices with
55. Buitrago J, Asfour S (2017) Short-term forecasting of electric recurrent neural networks: case study of crude oil price fluctua-
loads using nonlinear autoregressive artificial neural networks tions. Energy 102:365–374
with exogenous vector inputs. Energies 10(1):40 71. Cheng F, Fan T, Dandan F, Shanling L (2018) The prediction of
56. Demuth H, Beale M, Hagan M (1992) Neural network toolbox. oil price turning points with log-periodic power law and multi-
For Use with MATlAB. The MathWorks Inc, 2000 population genetic algorithm. Energy Econ 72:341–355
57. liu G, Wang X (2019) A new metric for individual stock trend 72. Hatcher WG, Yu W (2018) A survey of deep learning: Platforms,
prediction. Eng Appl Artif Intell 82:1–12 applications and emerging research trends. IEEE Access
58. Orimoloye LO, Sung M-C, Ma T, Johnson JEV (2020) Com- 6:24411–24432
paring the effectiveness of deep feedforward neural networks and 73. leCun Y, Bengio Y, Hinton G (2015) Deep learning. Nature
shallow architectures for predicting stock price indices. Expert 521:436–444
Syst Appl 139:112828 74. D O’Brien J, Dassios LK, Gleeson JP (2019) Spreading of memes
59. levenberg K (1944) A method for the solution of certain non- on multiplex networks. New J Phys 21:025001
linear problems in least squares. Q Appl Math 2(2):164–168 75. Ekhtiari A, Dassios L, Liu M, Syron E (2019) A novel approach
60. Marquardt DW (1963) An algorithm for least-squares estimation to model a gas network. Appl Sci 9:1047
of nonlinear parameters. J Soc Ind Appl Math 11(2):431–441 76. Dassios L, O’Keeffe G, Jivkov AP (2018) A mathematical model
61. Box GEP, Jenkins GM, Reinsel GC, Ljung GM (2015) Time for elasticity using calculus on discrete manifolds. Math Methods
series analysis: forecasting and control. Wiley, New York Appl Sci 41:9057–9070
62. Schmidhuber J (2015) Deep learning in neural networks: an
overview. Neural Netw 61:85–117 Publisher’s Note Springer Nature remains neutral with regard to
jurisdictional claims in published maps and institutional affiliations.
123