Next Article in Journal
Transformer-Based Parameter Estimation in Statistics
Previous Article in Journal
Existence, Uniqueness, and Averaging Principle of Fractional Neutral Stochastic Differential Equations in the Lp Space with the Framework of the Ψ-Caputo Derivative
Previous Article in Special Issue
Summary-Sentence Level Hierarchical Supervision for Re-Ranking Model of Two-Stage Abstractive Summarization Framework
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Hybrid DE-Optimized GPR and NARX/SVR Models for Forecasting Gold Spot Prices: A Case Study of the Global Commodities Market

by
Esperanza García-Gonzalo
1,
Paulino José García-Nieto
1,*,
Gregorio Fidalgo Valverde
2,
Pedro Riesgo Fernández
2,
Fernando Sánchez Lasheras
1 and
Sergio Luis Suárez Gómez
1
1
Department of Mathematics, Faculty of Sciences, University of Oviedo, 33007 Oviedo, Spain
2
School of Mining, Energy and Materials Engineering, University of Oviedo, 33004 Oviedo, Spain
*
Author to whom correspondence should be addressed.
Mathematics 2024, 12(7), 1039; https://doi.org/10.3390/math12071039
Submission received: 22 February 2024 / Revised: 26 March 2024 / Accepted: 27 March 2024 / Published: 30 March 2024

Abstract

:
In this work, we highlight three different techniques for automatically constructing the dataset for a time-series study: the direct multi-step, the recursive multi-step, and the direct–recursive hybrid scheme. The nonlinear autoregressive with exogenous variable support vector regression (NARX SVR) and the Gaussian process regression (GPR), combined with the differential evolution (DE) for parameter tuning, are the two novel hybrid methods used in this study. The hyper-parameter settings used in the GPR and SVR training processes as part of this optimization technique DE significantly affect how accurate the regression is. The accuracy in the prediction of DE/GPR and DE/SVR, with or without NARX, is examined in this article using data on spot gold prices from the New York Commodities Exchange (COMEX) that have been made publicly available. According to RMSE statistics, the numerical results obtained demonstrate that NARX DE/SVR achieved the best results.

1. Introduction

The global COVID-19 health crisis has caused misery and disaster ever since it started in early 2020. On 11 March 2020, the World Health Organization (WHO) declared this infectious disease to be a pandemic. As a result, several countries put in place a range of policies to try and stop the spread of the illness. Governments implemented various precautionary measures such as social distancing, workplace closures, travel limitations, and lockdowns, all to stop the disease from spreading.
This pandemic has had serious economic ramifications in addition to deaths, infections, and psychological damage. This unprecedented global health crisis has threatened the entire world and wreaked havoc on the economy by creating financial instability. The entire financial industry, including the insurance and banking sectors and the stock markets, has been impacted by COVID-19 [1]. Since the start of the pandemic, the financial markets have deteriorated and grown incredibly volatile, which has led to a drop in metal prices. The pandemic has also led to an unprecedented collapse in commodities markets, which are typically erratic. The COVID-19 outbreak caused borders to be closed and communities to be quarantined, which slowed down activity and restricted international trade in goods and commodities. In these circumstances, the supply of commodities frequently vastly outweighed their demand, leading to a decrease in commodity prices. Global investors shifted their holdings to commodities markets in the wake of the crisis and the ensuing market panic, which was accompanied by a chaotic macroeconomic and financial environment [2,3,4,5,6,7].
Gold has historically been the main commodity that best represents the commodities market [8]. According to several studies [9,10,11], gold is essentially the most highly valued metal. It has historically had a big impact on both politics and the economy. Therefore, the prices of gold and oil are the two most important indicators in the global markets [12]. Like gold, silver has many applications and can even be used as a hedge against inflation. According to metal experts, silver is perceived to be more volatile than gold [13]. The year 2020 saw a decline in the price of metals, something closely linked to the global economy. Due to these conditions, investors are growing more and more worried about the rise in commodity prices. Also, the price of gold increased rapidly in spite of a rise in COVID-19 cases [14]. In light of these modifications, the pandemic has promoted the buying of assets that serve as a safe haven [15]. Investor and regulatory interests in this phenomenon have caused a spike in the demand for certain commodities as investments. Therefore, understanding the relationships among the prices of gold, oil, and silver is crucial for investors, portfolio managers, and policymakers [16]. Many investors, especially novices, have traditionally placed their money in gold, which is considered a safe and trouble-free haven, to avoid complications [12]. In the years after the financial crisis, a common alternative in a variety of investment options was gold. Because it helps investors of all types manage their financial and economic concerns in times of crisis, gold is regarded as a safe-haven asset [15,17,18,19,20,21,22].
With the aforementioned points in mind, the current work attempts to explore the correlation between the price of gold and its status as a safe haven in relation to the different commodities indices under consideration. One volatility index is of particular interest to us: the gold price index [23,24]. Indeed, gold is one of the naturally occurring elements with the highest atomic number. It has the chemical symbol Au, and its atomic number is 79. In its purest form, it is reddish-yellow and bright. It is a very dense metal, ductile, malleable, and soft. Gold is a member of group 11 in the periodic table of chemical elements, and it is a transition metal [25]. Very unreactive, it is solid in normal circumstances. It usually appears as nuggets in veins, alluvial deposits, and rocks in its free elemental (native) form. It can also be found alloyed with other metals like palladium and copper, with the native element silver in solid solution series, and as mineral inclusions like those found in pyrite [25,26,27]. Gold is a precious metal used as a base material for coinage, jewelry, and other forms of art. It is not a common element. In the past, monetary policy used a gold standard, but after the 1930s, when gold was no longer used for coins as circulating currency, the world gold standard disappeared in favor of a flat currency system [25,26,27,28].
About 50% of the new gold produced worldwide nowadays is used for jewelry, with 40% for investments and approximately 10% in industry (see Figure 1). Due to gold’s high ductility, malleability, resistance to most other chemical reactions, particularly to corrosion, and high electrical conductivity, its main industrial use, as corrosion-resistant electrical connectors in all kinds of computers, has persisted. Additionally, the production of gold leafing, colored glass, and restoration of teeth all use gold. In medicine, specific gold salts are utilized as anti-inflammatories. China is the major producer with 440 tons of gold annually as of 2017.
Raw materials are essential for taking the pulse of the global economy, and these include precious metals. Some of these resources, like fossil fuels, are scarce. The demand, supply, and prices of precious metals have a significant influence on the production of precious metals. The London Metal Exchange (LME), the New York Commodity Exchange (COMEX), and the Shanghai Futures Exchange (SHFE) are the three main physical futures trading exchanges where gold is traded as a nonferrous metal [29,30,31]. Prices on these exchanges are a measure of the global situation between gold demand and supply, though they may be significantly impacted by investment flows and currency exchange rates, both of which could lead to volatile price swings that are at least partially correlated with changes in the business situation [32,33].
Forecasting gold prices holds significant relevance within the current economic context due to the metal’s multifaceted roles as a safe-haven asset, a store of value, and an indicator of market sentiment. As evidenced by numerous studies [34,35,36], gold prices are closely linked to geopolitical tensions, economic uncertainties, and investor risk aversion, making them invaluable indicators of market dynamics. Amidst the ongoing COVID-19 pandemic and its socio-economic ramifications, the demand for safe-haven assets like gold has surged, driving up prices and highlighting gold’s importance in hedging against inflation and market volatility [37]. Additionally, with the global economy facing challenges such as inflationary pressures, geopolitical conflicts, and monetary policy shifts, forecasting gold prices has become essential for investors, financial institutions, and policymakers to make informed decisions and effectively manage risks in their portfolios [17]. In this context, the accurate forecasting of gold prices provides valuable insights into market trends, aids in risk management strategies, and facilitates better allocation of resources, thereby contributing to greater overall financial stability and resilience.
Various methods have been employed in the past to predict metal prices. Using two time-series forecasting methods, Dooley and Lenihan (2005) [38] concluded that ARIMA works slightly better than the lagged forward price modeling. Multicommodity models were proposed [39] to assist in estimating long-term silver and copper prices. Artificial neuronal networks (ANNs) for time series were promoted by Khashei et al. (2010) [40]. The consumption and import of iron ore by China was studied [41] using a grey model with the particle swarm algorithm (PSO). To capture this cyclical behavior that dominates the metal market, Kriechbaumer et al. (2014) [42] broke down time series into their time domain and frequency. Finally, Sánchez Lasheras et al. (2015) [43] used the COMEX copper spot price as an example and contrast the forecasting abilities of two different neuronal networks and an ARIMA model.
Two new techniques to predict the COMEX gold spot are used in this article. The nonlinear autoregressive with exogenous variable, in this case the non-energy index, support vector regression (NARX DE/SVR) and the Gaussian process regression hybridized with the differential evolution optimizer (DE/GPR) in time-series analysis are new methodologies that are introduced in this paper for predicting the COMEX gold spot price [44,45,46,47,48,49]. The approach suggested successfully identifies nonlinear input features, tuning the parameters of SVR with RBF kernel.
This work starts with stating the importance of gold, and then it goes on to explain the experimental dataset used in this paper. The DE/GPR and NARX DE/SVR are described in Section 2; we compare the DE/GPR and NARX DE/SVR outcomes with the experimental values, and Section 3 explains the results. Finally, Section 4 presents a summary of this paper’s main findings.

2. Materials and Methods

2.1. Experimental Dataset

The monthly COMEX gold spot closing price was the primary data source for the current study, and, in fact, the dataset includes a time series of gold prices. Using the RBF kernel with the SVR method [47,48,49] and also with GPR along with DE for the parameter tuning [44], we estimated monthly gold prices for the years 2019 and 2020. The non-energy index was utilized to obtain a better model. The World Bank Commodity Price Data (The Pink Sheet) (2021) [50] was the source of the dataset. The goal of this project is to predict monthly gold prices for the full calendar years of 2019 and 2020.

2.2. Time-Series Analysis: Computational Procedures

2.2.1. Support Vector Machines Regression (SVR)

Here ε SVR is presented [48,49]. If we have time-series data, we can extract a training set that consists of a predicted variable y i R , i = 1,2 , , m that is continuous and independent variables x i R p ,   i = 1,2 , , m   that can be built using p lags of y i . As a result, the support vector regression ( ε SVR) technique creates f x = w T x + b where w R n denotes the hyperplane’s perpendicular vector, also known as the director vector and b / w denotes the distance between the hyperplane, with b R and the origin of the coordinates. Additionally, for all x i training cases, this approximation must give rise to a maximum deviation from the true value y i of ε and at the same time, must also be as flat as possible. The problem is modeled imposing a penalty on the sum of differences that exceeds ε , and flatness is attained finding the minimal Euclidean norm w 2 . In fact, the SVR approach aims to resolve the problem [51,52,53]:
min w , b , ξ + , ξ 1 2 w 2 + C i = 1 m ξ i + + ξ i
that meets the conditions
y i w T x i + b ε + ξ i + i = 1 , , m w T x i + b y i ε + ξ i i = 1 , , m ξ i + , ξ i 0 i = 1 , , m
ξ + , ξ R m are the slack variables, and C is the regularization constant. The penalty imposed on points that are not inside the interval ε is restrained by C in Equation (1) that is positive, which helps to prevent overfitting. This quantity measures the model complexity versus the function where we are optimizing horizontality [54,55,56,57]. For each training vector, slack variables are provided, allowing deviations that are greater than ε , while penalizing the deviations in the function. The area that y i ± ε ,   i encloses is called an ε insensitive tube (see Figure 2).
We employed the kernelization method to address problems like this one that are highly nonlinear. The foundation of this approach is the mapping of the initial dataset to a higher-dimensional space H , referred to as the feature space. For this, we used the kernel function K x i , x j for the dot product in H . This way, we formulated the primal optimization problem given by Equation (1) in its dual form to solve it. Applying the Karush–Kuhn–Tucker (KKT) conditions resulted in the dual formulation of the optimization problem [48,49,54,55,56,57]:
max α + , α i = 1 m y i α i + α i ε i = 1 m α i + + α i 1 2 j = 1 m α i + α i α j + α j K x i , x j
constricted to
i = 1 m α i + α i = 0 , 0 α i + C , i = 1 , , m 0 α i C , i = 1 , , m
We calculated the prediction for a new observation x [48,49,54,55,56,57] using:
f x = j = 1 m α i + α i K x i , x j + b
The radial basis function (RBF) is also called Gaussian kernel. This is one of the available kernel functions and is preferred in this study because of its better performance [48,49,54,55,56,57]:
K x i , x j = e σ x i x j 2
so that the RBF kernel’s typology is determined by the σ parameter.
The model was created with SVR–ε. LIBSVM [58] was used, and the tuning of the parameters was achieved with DE optimizer [44,59,60,61].

2.2.2. Gaussian Process Regression (GPR)

A Gaussian process is a stochastic process, where a set of random variables is defined with indices corresponding to time or space. For any finite linear combination, these random variables follow a multivariate normal distribution. The Gaussian process distribution, encompassing functions defined over a continuous domain such as space or time, represents the collective distribution of all these random variables [47,48,49].
Using lazy learning and the kernel function, the algorithm that employs a Gaussian process obtains a prediction for an unknown training data point. This estimation, which is a one-dimensional Gaussian distribution, is more than a prediction; it also provides its level of uncertainty. Multivariate Gaussian processes can be used for multi-output predictions, and the multivariate Gaussian distribution for these processes is the marginal distribution at each point [51].
Suppose that the training dataset is D = x i , y i / i = 1,2 , , N . The vectors x i R n include the relevant segregation parameters as well as the extracted or combined features. The observed values give the filtered volume and outlet turbidity of the filtration process. X = x i i ^ = 1 N is the matrix of the training dataset, which is used as input for obtaining the output vector y = y i i = 1 N . Once we have some data, we can transform the prior over functions that a Gaussian process f ( x ) converts into posterior over functions.
The mean m ( x ) and covariance function k x , x of a Gaussian process are the way to describe it. Then, the Gaussian process is [62,63]:
f x : G P m x , k x , x
and
m x = E f x k x , x = E f x m x f x m x T
The function m x is the predicted value of f x for the point X . The covariance function k x , x measures the confidence level for m x . The kernel k ( · , · ) must be a positive definite. To keep things simple, the mean function is typically set to zero, but when there is no prior knowledge of the mean variable, as is the case in this work, it is also reasonable to do so.
For the Gaussian process, the covariance function selection is crucial. It also goes by the name “prior” because it contains the assumptions made about the latent regression model [64]. The RBF covariance function and the affine mean function are expressed in this study as follows [49,65]:
k S E x , x = σ f 2 exp x x 2 2 l 2
where l is the length scale and σ f 2 the signal variance. The performance of the Gaussian process is directly impacted by the SE covariance function parameter. In this case, l controls the function’s change in horizontal scale, while σ f 2 controls its change in vertical scale. Most applications cannot achieve the function values f ( x ) . In actual use, only the noisy inputs are provided by [62,63,64,65]:
y = f x + ε
We assumed that Gaussian noise is independent and has an identical distribution such that ε : N 0 , σ n 2 , and that σ n is this noise’s standard deviation. This will make ε the additive white noise. An individual Gaussian process can also be made up of any finite number of the input values, as shown by [62,63,64,65]:
y : G P m x , k x , x + σ n 2 δ i j = G P 0 , k x , x + σ n 2 δ i j
so that δ i j is the Kronecker delta function indicated below as:
δ i j = 1 i f i = j 0 o t h e r w i s e
The goal is to predict, given the new point x * , the function f ¯ * and its variance C O V f * . In this context, X * represents the test dataset’s input matrix and N * its size. The observed and predicted values for a new point follow a joint Gaussian previous distribution [62,63,64,65]:
y f * : N 0 , K X , X + σ n 2 I K X , X * K X * , X K X * , X *
where
  • K X , X is the training dataset covariance matrix and K X * , X * is the test dataset covariance.
  • K X , X * is the training and test dataset covariance matrix and K X * , X = K X , X * T .
Because y and f * are jointly distributed, it is possible to condition the prior on the inputs and investigate how likely estimations for the f * are. That is [49,62,63,64,65]:
f * X * , X , y : N f ¯ * , c o v f *
where
f ¯ * = E f * X * , X , y = K X * , X K X , X + σ n 2 I 1 y
c o v f * = K X * , X * K X * , X K X , X + σ n 2 I 1 K X , X *
The prediction of new points can then be made using the ensuing distribution. In fact, the GPR model-predicted output value for the test point is f ¯ * . Additionally, the variance c o v f * is used to compute the confidence interval (CI) of the predicted output value. For example, the 95% CI is f * 2 × c o v f * , f ¯ * + 2 × c o v f * . As a result, the GPR model provides both the estimated values as well as the confidence level.
Finally, because the forecasted outputs of the GPR model only depend on the inputs x i and the values of y , this is a nonparametric model. Θ = l , σ f σ n are the GPR model hyperparameters. The final regression model was constructed using the Gpy module from the Gaussian process framework in Python [66].

2.2.3. Differential Evolution (DE) Optimizer

This is an approach used to optimize problems by making multiple attempts to improve the quality of a potential solution. DE was first presented by Storn and Price in the 1990s [44]. They are metaheuristic techniques because they have the ability to explore extensive solution spaces without relying on specific assumptions about the problem [52]. In contrast to conventional optimization methods, such as gradient descent, which rely on differentiability of the optimization problem, DE utilizes multidimensional real-valued functions instead of the problem’s gradient to solve it [53,54,59,60,61,67]. DE keeps a group of potential solutions and uses straightforward formulae to combine existing solutions to produce new ones. Subsequently, it retains the candidate solution that possesses the highest score, thus eliminating the need for a gradient. It also offers a quality estimation of the possible solution [53,54,61,67].
Differential Evolution (DE) can be employed to optimize a problem by iteratively enhancing the fitness of a possible solution. The efficiency of the Differential Evolution (DE) optimizer extends to multidimensional real-valued data, as it can successfully handle non-differentiable optimized functions. Additionally, the DE optimizer can be applied to dynamic, noisy, or non-continuous problems, showcasing its versatility across various challenging scenarios. DE optimization involves managing a potential solution population, combining it through straightforward formulae. The method optimizes by retaining the fittest solution for the given optimization problem [44]. The technique encapsulates the variables of the optimization problem, representing them as a vector. The population comprises N P vectors, representing the actual population, where the length of each vector, n , is the input variable number for the problem at hand.
If p denotes the index of a vector within the population p = 1 , , N P and g represents the generation, we defined the vector as x p g . The components of this vector represent the input variables, denoted as x p , m g , and m is the index m = 1 , , n . The parameters in the problem are constrained within intervals limited by x m m i n and x m m a x , representing the minimum and maximum bounds, respectively. The steps of the DE algorithm are as follows [59,60,61,67]:
  • Initialization;
  • Mutation;
  • Recombination;
  • Selection.
After the initialization, the search begins. The mutation–recombination–selection phases conclude when a stopping criterion, such as a specified number of generations, a time threshold, or a desired level of solution attainment, is satisfied.
  • Initialization
During the initialization of the population in the first generation, each variable is assigned a random value within its respective minimum and maximum bounds [59,60,61,67]:
x p , m 1 = x m m i n + r a n d   ( 0,1 ) · x m m a x x m m i n   for   p = 1 , , N P   and   m = 1 , , n
where the random number within the interval 0,1 is r a n d   ( 0,1 ) .
  • Mutation
Creating the mutation involves selecting three individuals, randomly referred to as target vectors x a , x b , and x c . These individuals are then used to generate N P new vectors. The process for creating the n p t new vectors is outlined below [59,60,61,67]:
n p t = x c + F · x a x b   for   p = 1 , , N P
with the distinct individuals labeled as a , b , c , and p , the mutation rate is controlled by F , which falls within 0,2 .
  • Recombination
After generating the NP new vectors, we obtained the trial vectors t m g that are formed by applying recombination in a random way and by comparing the outcomes with the previous vectors x p g [59,60,61,67]:
t p , m g = n p , m g i f   r a n d   0,1 < G R x p , m g o t h e r w i s e   for   p = 1 , , N P   and   m = 1 , , n
Regulated by the rate of recombination G R , the creation of trial vectors involves a combination of updated and original vectors. This is performed individually for each variable.
  • Selection
To select the vectors for the subsequent generation, determined by the best values obtained from the fitness function, a straightforward comparison is made between the test vectors and the original vectors [59,60,61,67]:
x p g + 1 = t p g i f   f i t   t p g > f i t   x p g x p g o t h e r w i s e

2.3. Accuracy of This Approach

The COMEX gold spot price is the variable we tried to predict. To ensure a reliable forecast of the COMEX gold spot price using the selected input variables, we needed to find the best model. Subsequently, we compared the observed values t i with the model-estimated values y i . In this study, three criteria were examined to estimate fit quality: the root mean square error (RMSE) [68], the mean absolute error (MAE), and the mean absolute percentage error (MAPE) [69,70]. These statistical measures are commonly utilized to compute the accuracy of a mathematical model as well. Their expressions are [69,70]:
R M S E = i = 1 n t i y i 2 n
M A E = i = 1 n t i y i n
M A P E = 100 % n i = 1 n t i y i t i
If the RMSE is null, there is an exact match between the observed and predicted values, implying no difference between them. MAE is the average of the absolute difference between the target variable t i and the predicted variable y i . Finally, MAPE is frequently employed as a loss function for regression problems and in the evaluation of models. This is due to its highly intuitive interpretation in relation to relative error. Finally, R2 was also calculated for the three models considered of the most interest [70].

2.4. Numerical Schemes

The monthly prices that were predicted began in January 2019 and ended in December 2019, and subsequently started in January 2020 and finished in December 2020. The dataset used for training included information ranging from January 1960 to March 2021. Therefore, in this specific instance, we needed to predict twelve future steps. As a result, we executed a multi-step forecast. The following three methods are used to create the training data:
  • Direct multi-step;
  • Recursive multi-step;
  • Direct–recursive hybrid.
Since the beginning, we used only one variable, namely, the gold price in the previous years. The non-energy index was added as an exogenous variable after this model was created, resulting in the NARX model. Following that, we went over the three different approaches to this multi-step forecasting problem. Here, the variables were standardized.
  • Direct multi-step (DM)
Under this approach, we built separate models for each prediction. If p stands for prediction, o for observation, and m for model:
p t + 1 = m 1 o t , o t 1 , , o ( t r ) p t + 2 = m 2 o t , o t 1 , , o ( t r ) p t + 12 = m 12 o t , o t 1 , , o ( t r )
The training dataset remained the same across all models, as is evident. However, twelve distinct models were created, with each model dedicated to a specific prediction. Four variables affected how these models perform. The first is the lag, or the length of time between observations. We employed r + 1 observations for each model in this situation. One or more variables may be present in the observations at any given time. The gold price was our sole variable when we began. The final three variables were those that relate to the chosen method, SVR with an RBF kernel and/or GPR with an RBF kernel in this situation. These four parameters were optimized using the DE optimizer.
  • Recursive multi-step (RM)
In this instance, we created a model that is potentially identical to the first model in the previous technique. Then, we simply predicted the subsequent value at each step. We then took into account the predicted value, discarded the most recent value, and forecasted the following value. Thus, following the model construction, if p stands for prediction, o for observation, and m for model, the following prediction procedure is indicated as:
p t + 1 = m o t , o t 1 , , o ( t r ) p t + 2 = m p t + 1 , o t , o t 1 , , o ( t r + 1 ) p t + 3 = m p t + 2 , p t + 1 , o t , o t 1 , , o ( t r + 2 ) p t + 12 = m p t + 11 , p t + 10 , , o ( t r + 12 )
Indeed, we have a distinctive model, as is evident. When making predictions one step forward, we took the most recent prediction into account and discarded the earliest observation. The same factors applied as in the prior instance.
  • Direct–recursive hybrid (DH)
The two previous numerical systems were combined in this numerical scheme. For each prediction, we developed a unique model, but during the prediction phase, the models incorporated the forecasted values. In this instance, as we moved closer to the prediction, the lag for each model grew. In other words, if the first model started with r + 1 observations, the second model utilized an additional data point as it incorporated the newly predicted value during the forecasting phase. If p stands for prediction, o for observation, and m for model:
p t + 1 = m 1 o t , o t 1 , , o ( t r ) p t + 2 = m 2 p t + 1 , o t , o t 1 , , o ( t r ) p t + 3 = m 3 p t + 2 , p t + 1 , o t , o t 1 , , o ( t r ) p t + 12 = m 12 p t + 11 , p t + 10 , , o ( t r )
In this instance, we did not discard earlier observations as we moved closer to the prediction.

3. Results and Discussion

The methods for building the dataset used two distinct sets of variables: the gold price and the non-energy index that is the exogenous variable.
The first 600 months were eliminated because they did not alter the outcomes. This could be due to the fact that prices during a specific timeframe generally align with patterns observed in the preceding cycles. The price of gold is influenced by numerous political, social, and economic variables. They evolve over time, and similar situations from the past do not recur today. The dataset used for training was built from the recorded monthly gold prices spanning from January 1960 to March 2021. The lag affects how many training samples are used. A smaller lag implies a higher number of samples with identical data, as each sample encompasses a shorter time period and incorporates fewer observations. During the training phase, no data pertaining to the forecasted period (including the subsequent period) were employed. The objective was to predict monthly prices specifically for the 12 months of 2019 and the 12 months of 2020.
Table 1 and Table 2 present the mean absolute percentage error (MAPE) for the four distinct models during the years 2019 and 2020.
Table 1 and Table 2 show the following:
  • For 2020, the year of the pandemic, the MAPEs are the worst. It seems reasonable to attribute this to the atmosphere of unpredictability brought on by the pandemic’s numerous, unprecedented, and unexpected changes.
  • The results obtained with only one variable are generally improved by the NARX models, though this is not always the case.
  • The best models were obtained by using strategy 1.
Next, we will now choose the two best models for 2019 and the best model for 2020, and we will go into detail about their development and outcomes. The three top models are presented in Table 3 with the ideal parameters chosen by DE.
The accuracy for these models is shown in Table 4.
Finally, Figure 3 displays the predicted and observed COMEX gold spot price values for the years 2019 (Model 1), 2020 (Model 3), and 2021 (Model 2) using the NARX DE/SVR, DE/GPR, and DE/GPR predictor methods, respectively.
The outcomes of the gold price forecasting models hold significant implications for both investors and policymakers within the realm of the gold market. For investors, the accuracy and reliability of these models can serve as invaluable tools for decision-making processes, particularly in portfolio diversification and risk management strategies. By utilizing such forecasting models, investors can gain insights into potential future movements in gold prices, enabling them to adjust their investment positions accordingly to thereby optimize returns and mitigate risks. Moreover, the ability to anticipate fluctuations in gold prices can aid investors in identifying opportune moments for buying or selling gold assets, thus enhancing their overall investment performance.
On the other hand, for policymakers, the findings from these forecasting models offer insights into the dynamics and drivers of gold price movements, which can inform policy decisions related to economic stability and monetary policy formulation. Understanding anticipated trends in gold prices can help policymakers assess their potential impact on inflation, currency valuations, and overall market sentiment. Additionally, by incorporating these forecasts into their policy frameworks, policymakers can adopt proactive measures to mitigate adverse effects stemming from volatile gold prices, thereby fostering greater economic resilience and stability. Overall, the integration of gold price forecasting models into both investment and policymaking practices represents a critical advancement in navigating the complexities of the gold market, ultimately enhancing decision-making processes and fostering more robust market outcomes.
Taking into account the results obtained in this paper, it can be said that DE/GPR leverages the robustness of GPR in handling noisy data and providing uncertainty estimates alongside predictions. Through the incorporation of DE, an optimization algorithm inspired by natural selection, DE/GPR efficiently adapts model parameters to fit complex data distributions, offering enhanced robustness and flexibility. The synergy between GPR and DE results in a computationally efficient approach with fewer hyperparameters to tune, making DE/GPR particularly appealing for tasks where accurate modeling of uncertainty and adaptability to diverse datasets are paramount.
In the case of NARX DE/SVR, this methodology combines the nonlinear modeling capabilities of SVR with the efficiency and adaptability of DE. Please also note that SVR excels in capturing intricate nonlinear relationships while maintaining robustness against overfitting by means of implicit feature selection and structural risk minimization. When coupled with Differential Evolution, NARX DE/SVR achieves superior generalization performance and tolerance to outliers, rendering it suitable for diverse applications where accurate predictions on unseen data instances are imperative. This amalgamation stands as a good example of the effectiveness of combining evolutionary optimization with robust regression techniques for addressing complex real-world problems.
But the proposed methodologies also have certain limitations that must be taken into account. These limitations can profoundly influence their outcomes in diverse applications. Firstly, DE/GPR’s utilization of GPR, while advantageous for handling noisy data and providing uncertainty estimates, faces computational complexity challenges, particularly with large datasets due to its time complexity. Despite the incorporation of DE for parameter optimization, this computational burden may limit scalability. Furthermore, GPR’s sensitivity to hyperparameters like kernel choice and parameters can significantly impact model performance, necessitating careful tuning. Additionally, the inherent complexity of GPR models may hinder interpretability, posing challenges in understanding the reasoning behind predictions, especially in domains where interpretability is crucial. On the other hand, NARX DE/SVR’s amalgamation of SVR with DE introduces complexities in model interpretation and parameter sensitivity. SVR’s tendency to produce complex models, especially with high-dimensional or nonlinear data, poses interpretability challenges, and tuning hyperparameters such as the regularization parameter and kernel parameters is crucial for optimal performance. However, these constraints can influence outcomes by necessitating trade-offs among model complexity, computational efficiency, and predictive performance. Striking the right balance requires careful consideration of hyperparameter tuning, computational resources, and interpretability needs, ultimately impacting the performance and suitability of DE/GPR and NARX DE/SVR for specific tasks and datasets.

4. Conclusions

The hybrid models constructed in this study utilized variables configured in three different ways. The output variable of this proposed hybrid models, based on support vector machines (SVM) [71] and GPR, is the COMEX gold spot price. The metaheuristic optimizer differential evolution (DE) [44,59,60,61,67] was employed to obtain the optimal parameters for SVM and GPR.
Based on the numerical results obtained from publicly available data on gold in the COMEX market, it can be concluded that Model 1 (NARX DE/SVR technique) is the most accurate predictor, as indicated by the RMSE statistic. Models 2 and 3 follow in terms of accuracy. However, when considering the MAPE and MAE statistics, Model 2 emerges as the best predictor, followed by Models 1 and 3. Additionally, it should be noted that the direct multi-step scheme yields the most optimal models. In the case of the R2 metric, the most accurate model is Model 1, followed by Model 3 and Model 1. Please also note that although R2 values are low, the good MAE, MAPE, and RMSE obtained suggest the model can make accurate predictions in terms of the magnitude and direction of the forecasted values. In such cases, the model can be considered accurate for forecasting purposes, especially if the primary goal is to minimize forecasting errors rather than explaining the variance in the data.
The forecasted gold prices generated by the DE/GPR and NARX DE/SVR models hold significant implications for all the stakeholders in the gold market. For example, investors and traders can utilize these forecasts to strategize their buying, selling, or holding decisions regarding gold assets. Through an analysis of the predicted price movements, investors can devise trading strategies, leveraging the timing of purchases or sales based on expected trends. Moreover, the forecasts empower traders to identify potential opportunities for arbitrage or speculation within the gold markets, optimizing their investment portfolios and capitalizing on market dynamics.
For gold mining companies, the forecasted gold prices offer invaluable insights for optimizing production strategies. By anticipating future price trends, mining companies can adjust production levels to maximize profitability. During periods of anticipated price increases, ramping up production can capitalize on higher prices, while during downturns, scaling back production helps minimize losses. Financial institutions, including banks and investment firms, can integrate the forecasted gold prices into their risk management and portfolio optimization strategies. By managing exposure to gold-related assets more effectively and hedging against price fluctuations, financial institutions can offer gold-linked financial products, such as exchange-traded funds (ETFs), tailored to client needs, enhancing portfolio performance and risk mitigation.
Also, central banks and governments can leverage forecasted gold prices to inform monetary policy decisions and reserve management practices. As gold prices often reflect broader economic trends and market sentiment, monitoring these forecasts enables policymakers to adjust gold reserve holdings and implement policies effectively, stabilizing economies and managing inflationary pressures. Jewelry and industrial manufacturers relying on gold as a raw material can optimize procurement and production processes through forecasted price insights. By negotiating better prices with suppliers and hedging against price fluctuations with forward contracts or options, manufacturers minimize costs and enhance operational efficiency. In essence, the forecasted gold prices derived from the DE/GPR and NARX DE/SVR models provide invaluable guidance across the gold market landscape, enabling stakeholders to make informed decisions and mitigate risks associated with gold price volatility.
In conclusion, we hold the belief that there is a bright outlook for research endeavors that merge hybrid models capable of harnessing the full potential of SVR and GPR models. Such models have the potential to combine various machine learning techniques, paving the way for innovative advancements in the field. Furthermore, these innovative techniques based on statistical machine learning have proven to be better than classical time-series techniques such as the ARIMA model at foretelling the price of other metals such as copper [43] and thermal coal [72] or even the forecasting of pollution incidents [73].
Finally, it can be said that researchers can explore various methodologies to develop more accurate and reliable forecasting models for gold prices, including long short-term memory (LSTM) [74], Prophet [75], ensemble methods, hybrid models, deep learning architectures [76], etc. LSTM is a type of recurrent neural network and is effective at capturing long-term dependencies in sequential data, making it promising for forecasting tasks in financial markets. Prophet, developed by Facebook, is tailored to handle time-series data with strong seasonal patterns, making it suitable for forecasting gold prices, which exhibit complex seasonal and cyclical patterns. Ensemble methods combine multiple models to improve predictive performance, while hybrid models integrate different techniques to leverage their complementary strengths. Deep learning architectures like convolutional neural networks [77] and transformer-based models [78], offer additional avenues for exploring and understanding gold price dynamics, enabling researchers to develop more informed decision-making tools for the gold market.

Author Contributions

E.G.-G.: Formal analysis, Data curation, Investigation, Writing—original draft, Visualization, Conceptualization, Methodology, and Software. P.J.G.-N.: Formal analysis, Data curation, Investigation, Visualization, Writing—original draft, Supervision, Conceptualization, Methodology, and Software. G.F.V.: Formal analysis, Investigation, Data curation, Writing—original draft, Conceptualization, and Methodology. P.R.F.: Formal analysis, Data curation, Investigation, Writing—original draft, Conceptualization, Visualization, Methodology, and Software. F.S.L.: Methodology, Investigation, Formal analysis, Data curation, Visualization, and Writing—original draft. S.L.S.G.: Methodology, Validation, and Writing—review and editing. All authors have read and agreed to the published version of the manuscript.

Funding

This research was funded by Plan Nacional by Ministerio de Ciencia, Innovación y Universidades, Spain, grant number MCINN-23-pID2022-139198NB-100.

Data Availability Statement

Data and source code will be made available on request.

Acknowledgments

We would like to acknowledge the Oviedo University Mathematics Department for providing computational support. We would also like to acknowledge the funding from Plan Nacional by Ministerio de Ciencia, Innovación y Universidades, Spain, grant number MCINN-23-pID2022-139198NB-100. Additionally, we are grateful to Anthony Ashworth for correcting the English spelling and grammar in this study.

Conflicts of Interest

The authors declare no conflict of interest.

References

  1. Goodell, J.W.; Huynh, T.L.D. Did Congress trade ahead? Considering the reaction of US industries to COVID-19. Financ. Res. Lett. 2020, 36, 101578. [Google Scholar] [CrossRef]
  2. Bampinas, G.; Panagiotidis, T. On the relationship between oil and gold before and after financial crisis: Linear, nonlinear and time-varying causality testing. Stud. Nonlinear Dyn. Econom. 2015, 19, 657–668. [Google Scholar] [CrossRef]
  3. Chaya, J.; Azar, S.A.; Khakhar, P. Financial non-neutrality; A link between income inequality and aggregated debt characteristics in the United-States. Int. J. Soc. Sci. Humanit. Stud. 2021, 13, 29–54. [Google Scholar]
  4. Haaskjold, H.; Aarseth, W.K.; Røkke, T.A.; Ivarson, M. Spinning the IPD Wheels- Moving towards frictionless project delivery. J. Mod. Proj. Manag. 2021, 9, 70–87. [Google Scholar]
  5. Rodríguez, A.C.; Aguilar, J.L.; Arbiol, I.A. Relationship between physical physiological and psychological responses in amateur soccer referees. Rev. Psicol. Deporte 2021, 30, 26–37. [Google Scholar]
  6. Iglesias García, C.; Saiz Matinez, P.; García-Portilla González, M.P.; Bousoño García, M.; Jiménez Treviño, L.; Sánchez Lasheras, F.; Bobes, J. Effects of the economic crisis on demand due to mental disorders in Asturias: Data from the Asturias Cumulative Psychiatric Case Register (2000–2010). Actas Españolas Psiquiatr. 2014, 42, 108–115. [Google Scholar]
  7. Iglesias-García, C.; Sáiz, P.A.; Burón, P.; Sánchez-Lasheras, F.; Jiménez-Treviño, L.; Fernández-Artamendi, S.; Bobes, J. Suicidio, desempleo y recesión económica en España. Rev. De Psiquiatr. Y Salud Ment. 2017, 10, 70–77. [Google Scholar] [CrossRef]
  8. Tuan, B.A.; Pho, K.H.; Pan, S.H.; Wong, W.K. Applications in sciences in the prevention of COVID-19. Adv. Decis. Sci. 2022, 26, 1–16. [Google Scholar]
  9. Hoang, V.T.H.; Wong, W.K.; Zhu, Z.Z. Is gold different for risk-averse and risk seeking investors? An empirical analysis of the Shanghai Gold Exchange. Econ. Model. 2015, 50, 200–211. [Google Scholar] [CrossRef]
  10. Hoang, V.T.H.; Zhu, Z.Z.; Xiao, B.; Wong, W.K. The seasonality of gold prices in China: Does the risk-aversion level matter? Account. Financ. 2018, 60, 2617–2664. [Google Scholar] [CrossRef]
  11. Hoang, V.T.H.; Zhu, Z.Z.; Khamlichi, A.E.; Wong, W.K. Does the Shari’ah screening impact the gold-stock nexus? A sectorial analysis. Resour. Policy 2019, 61, 617–626. [Google Scholar] [CrossRef]
  12. Eryigit, M. Short-term and long-term relationships between gold prices and precious metal (palladium, silver and platinum) and energy (crude oil and gasoline) prices. Econ. Res. Ekon. Istraživanja 2017, 30, 499–510. [Google Scholar] [CrossRef]
  13. Yaya, O.S.; Vo, X.V.; Olayinka, H.A. Gold and silver prices, their stocks and market fear gauges: Testing fractional cointegration using a robust approach. Resour. Policy 2021, 72, 102045. [Google Scholar] [CrossRef]
  14. Atri, H.; Kouki, S.; imen Gallali, M. The impact of COVID-19 news, panic and media coverage on the oil and gold prices: An ARDL approach. Resour. Policy 2021, 72, 102061. [Google Scholar] [CrossRef] [PubMed]
  15. Tanin, T.I.; Sarker, A.; Hammoudeh, S.; Shahbaz, M. Do volatility indices diminish gold’s appeal as a safe haven to investors before and during the COVID-19 pandemic? J. Econ. Behav. Organ. 2021, 191, 214–235. [Google Scholar] [CrossRef] [PubMed]
  16. Alawi, A.H. Media and intercultural communication shifts: A semiotic analysis of the cultural identity in two international films. Croat. Int. Relat. Rev. 2021, 27, 1–13. [Google Scholar]
  17. Agyei-Ampomah, S.; Gounopoulos, D.; Mazouz, K. Does gold offer a better protection against losses in sovereign debt bonds than other metals? J. Bank. Financ. 2014, 40, 507–521. [Google Scholar] [CrossRef]
  18. Balcilar, M.; Gupta, R.; Pierdzioch, C. Does uncertainty move the gold price? New evidence from a nonparametric causality-in-quantiles test. Resour. Policy 2016, 49, 74–80. [Google Scholar] [CrossRef]
  19. Baur, D.G.; McDermott, T.K. Is gold a safe haven? International evidence. J. Bank. Financ. 2010, 34, 1886–1898. [Google Scholar] [CrossRef]
  20. Bilgin, M.H.; Gozgor, G.; Lau, C.K.M.; Sheng, X. The effects of uncertainty measures on the price of gold. Int. Rev. Financ. Anal. 2018, 58, 1–7. [Google Scholar] [CrossRef]
  21. Bouoiyour, J.; Selmi, R.; Wohar, M.E. Measuring the response of gold prices to muncertainty: An analysis beyond the mean. Econ. Model. 2018, 75, 105–116. [Google Scholar] [CrossRef]
  22. Beckmann, J.; Berger, T.; Czudaj, R. Gold price dynamics and the role of uncertainty. Quant. Financ. 2019, 19, 663–681. [Google Scholar] [CrossRef]
  23. Maghyereh, A.I.; Abdoh, H. Connectedness between crude oil and US equities: The impact of COVID-19 pandemic. Annu. Rev. Econ. 2022, 17, 2250029. [Google Scholar] [CrossRef]
  24. Arfaoui, M.; Rejeb, A.B. Oil, gold, US dollar and stock market interdependencies: A global analytical insight. Eur. J. Manag. Bus. Econ. 2017, 26, 278–293. [Google Scholar] [CrossRef]
  25. Macdonald, E. Handbook of Gold Exploration and Evaluation; Woodhead Publishing: New York, NY, USA, 2007. [Google Scholar]
  26. Stevens, R. Mineral Exploration and Mining Essentials; Robert Stevens Publishing: London, UK, 2011. [Google Scholar]
  27. Skonieczny, M. Gold Production from Beginning to End: What Gold Companies Do to Get the Shiny Metal into Our Hands; Investment Publishing: New York, NY, USA, 2015. [Google Scholar]
  28. U.S. Geological Survey. Gold, Mineral Commodity Summaries. 2018. Available online: https://www.usgs.gov/centers/nmic/gold-statistics-and-information (accessed on 10 March 2024).
  29. Streifel, S. Impact of China and India on Global Commodity Markets Focus on Metals & Minerals and Petroleum, Report. 2006. Available online: http://www.tos.camcom.it/Portals/_UTC/Studi/ScenariEconomici/39746563551035393/ChinaIndiaCommodityImpact.pdf (accessed on 10 March 2024).
  30. Cuddington, J.T.; Jerrett, D. Super Cycles in Real Metals Prices? IMF Econ. Rev. 2008, 55, 541–565. [Google Scholar] [CrossRef]
  31. Roache, S.K. China’s Impact on World Commodity Markets. IMF Working Paper No. 12/115. 2012. Available online: https://ssrn.com/abstract=2127010 (accessed on 10 March 2024).
  32. Gordon, R.B.; Bertram, M.; Graedel, T.E. Metal stocks and sustainability. Proc. Natl. Acad. Sci. USA 2006, 103, 1209–1214. [Google Scholar] [CrossRef] [PubMed]
  33. Tilton, J.E.; Lagos, G. Assessing the long-run availability of copper. Resour. Policy 2007, 32, 19–23. [Google Scholar] [CrossRef]
  34. Li, J.; Wang, R.; Aizhan, D.; Karimzade, M. Assessing the impacts of COVID-19 on stock exchange, gold prices, and financial markets: Fresh evidences from econometric analysis. Resour. Policy 2023, 83, 103617. [Google Scholar] [CrossRef]
  35. Baur, D.G.; Lucey, B.M. Is Gold a Hedge or a Safe Haven? An Analysis of Stocks, Bonds and Gold. Financ. Rev. 2010, 45, 217–229. [Google Scholar] [CrossRef]
  36. Corbet, S.; Larkin, C.; Lucey, B. The contagion effects of the COVID-19 pandemic: Evidence from gold and cryptocurrencies. Financ. Res. Lett. 2020, 35, 101554. [Google Scholar] [CrossRef]
  37. Ji, Q.; Zhang, D.; Zhao, Y. Searching for safe-haven assets during the COVID-19 pandemic. Int. Rev. Financ. Anal. 2020, 71, 101526. [Google Scholar] [CrossRef]
  38. Dooley, G.; Lenihan, H. An assessment of time series methods in metal price forecasting. Resour. Policy 2005, 30, 208–217. [Google Scholar] [CrossRef]
  39. Cortazar, G.; Eterovic, F. Can oil prices help estimate commodity futures prices? The cases of copper and silver. Resour. Policy 2010, 35, 283–291. [Google Scholar] [CrossRef]
  40. Khashei, M.; Bijari, M. An artificial neural network (p,d,q) model for time series forecasting. Expert. Syst. Appl. 2010, 37, 479–489. [Google Scholar] [CrossRef]
  41. Ma, W.; Zhu, X.; Wang, M. Forecasting iron ore import and consumption of China using grey model optimized by particle swarm optimization algorithm. Resour. Policy 2013, 38, 613–620. [Google Scholar] [CrossRef]
  42. Kriechbaumer, T.; Angus, A.; Parsons, D.; Rivas Casado, M. An improved wavelet–ARIMA approach for forecasting metal prices. Resour. Policy 2014, 39, 32–41. [Google Scholar] [CrossRef]
  43. Sánchez Lasheras, F.; de Cos Juez, F.J.; Suárez Sánchez, A.; Krzemień, A.; Riesgo Fernández, P. Forecasting the COMEX copper spot price by means of neural networks and ARIMA models. Resour. Policy 2015, 45, 37–43. [Google Scholar] [CrossRef]
  44. Storn, R.M.; Price, K. Differential evolution—A simple and efficient heuristic for global optimization over continuous spaces. J. Glob. Optim. 1997, 11, 341–359. [Google Scholar] [CrossRef]
  45. Brockwell, P.J.; Davis, R.A. Introduction to Time Series and Forecasting; Springer: New York, NY, USA, 2016. [Google Scholar]
  46. Shumway, R.H.; Stoffer, D.S. Time Series Analysis and Its Applications: With R Examples; Springer: New York, NY, USA, 2017. [Google Scholar]
  47. Rasmussen, C.E. Gaussian Processes in Machine Learning: Summer School on Machine Learning; Springer: Berlin/Heidelberg, Germany, 2003. [Google Scholar]
  48. Hastie, T.; Tibshirani, R.; Friedman, J. The Elements of Statistical Learning: Data Mining, Inference, and Prediction; Springer: New York, NY, USA, 2016. [Google Scholar]
  49. Kuhn, M.; Johnson, K. Applied Predictive Modeling; Springer: New York, NY, USA, 2018. [Google Scholar]
  50. World Bank Commodity Price Data (The Pink Sheet). Bloomberg, Engineering and Mining Journal; Platts Metals Week; and Thomson Reuters Datastream; World Bank. 2021. Available online: http://pubdocs.worldbank.org/en/561011486076393416/CMO-Historical-Data-Monthly.xlsx (accessed on 10 March 2024).
  51. Vapnik, V. Statistical Learning Theory; Wiley–Interscience: New York, NY, USA, 1998. [Google Scholar]
  52. Cristianini, N.; Shawe–Taylor, J. An Introduction to Support Vector Machines and Other Kernel–Based Learning Methods; Cambridge University Press: New York, NY, USA, 2000. [Google Scholar]
  53. Schölkopf, B.; Smola, A.J.; Williamson, R.C.; Bartlett, P.L. New support vector algorithms. Neural Comput. 2000, 12, 1207–1245. [Google Scholar] [CrossRef]
  54. Hansen, T.; Wang, C.J. Support vector based battery state of charge estimator. J. Power Sources 2005, 141, 351–358. [Google Scholar] [CrossRef]
  55. Li, X.; Lord, D.; Zhang, Y.; Xie, Y. Predicting motor vehicle crashes using Support Vector Machine models. Accid. Anal. Prev. 2008, 40, 1611–1618. [Google Scholar] [CrossRef] [PubMed]
  56. Steinwart, I.; Christmann, A. Support Vector Machines; Springer: New York, NY, USA, 2008. [Google Scholar]
  57. Hamel, L.H. Knowledge Discovery with Support Vector Machines; Wiley-Interscience: New York, NY, USA, 2011. [Google Scholar]
  58. Chang, C.-C.; Lin, C.-J. LIBSVM: A library for support vector machines. ACM Trans. Intell. Syst. Technol. 2011, 2, 1–27. [Google Scholar] [CrossRef]
  59. Price, K.; Storn, R.M.; Lampinen, J.A. Differential Evolution: A Practical Approach to Global Optimization; Springer: Berlin/Heidelberg, Germany, 2005. [Google Scholar]
  60. Feoktistov, V. Differential Evolution: In Search of Solutions; Springer: New York, NY, USA, 2006. [Google Scholar]
  61. Rocca, P.; Oliveri, G.; Massa, A. Differential evolution as applied to electromagnetics. IEEE Trans. Antennas Propag. 2011, 53, 38–49. [Google Scholar] [CrossRef]
  62. Rasmussen, C.E.; Williams, C.K.I. Gaussian Processes for Machine Learning; MIT Press: Cambridge, MA, USA, 2006. [Google Scholar]
  63. Marsland, S. Machine Learning: An Algorithmic Perspective; Chapman and Hall/CRC Press: Boca Raton, FL, USA, 2014. [Google Scholar]
  64. Schneider, M.; Ertel, W. Robot learning by demonstration with local Gaussian process regression. In Proceedings of the IEEE/RSJ International Conference on Intelligent Robots and Systems, Taipei, Taiwan, 18–22 October 2010; pp. 255–260. [Google Scholar]
  65. Shi, J.Q.; Choi, T. Gaussian Process Regression Analysis for Functional Data; Chapman and Hall/CRC Press: Boca Raton, FL, USA, 2011. [Google Scholar]
  66. GPy: A Gaussian process framework in Python. Available online: http://sheffieldml.github.io/GPy/ (accessed on 23 June 2023).
  67. Chakraborty, U.K. Advances in Differential Evolution; Springer: Berlin/Heidelberg, Germany, 2008. [Google Scholar]
  68. Artime Ríos, E.M.; Sánchez Lasheras, F.; Suarez Sánchez, A.; Iglesias-Rodríguez, F.J.; Seguí Crespo, M.M. Prediction of Computer Vision Syndrome in Health Personnel by Means of Genetic Algorithms and Binary Regression Trees. Sensors 2019, 19, 2800. [Google Scholar] [CrossRef] [PubMed]
  69. Wasserman, L. All of Statistics: A Concise Course in Statistical Inference; Springer: New York, NY, USA, 2003. [Google Scholar]
  70. Freedman, D.; Pisani, R.; Purves, R. Statistics; WW Norton & Company: New York, NY, USA, 2007. [Google Scholar]
  71. Casteleiro-Roca, J.L.; Jove, E.; Sánchez-Lasheras, F.; Méndez-Pérez, J.A.; Calvo-Rolle, J.L.; de Cos Juez, F.J. Power Cell SOC Modelling for Intelligent Virtual Sensor Implementation. J. Sens. 2017, 2017, 9640546. [Google Scholar] [CrossRef]
  72. Krzemień, A.; Riesgo Fernández, P.; Suárez Sánchez, A.; Sánchez Lasheras, F. Forecasting European thermal coal spot prices. J. Sustain. Min. 2015, 14, 203–210. [Google Scholar] [CrossRef]
  73. Sánchez, A.B.; Ordóñez, C.; Sánchez Lasheras, F.; de Cos Juez, F.J.; Roca-Pardiñas, J. Forecasting SO2Pollution Incidents by means of Elman Artificial Neural Networks and ARIMA Models. Abstr. Appl. Anal. 2013, 2013, 238259. [Google Scholar] [CrossRef]
  74. Liu, K.; Cheng, J.; Yi, J. Copper price forecasted by hybrid neural network with Bayesian Optimization and wavelet transform. Resour. Policy 2022, 75, 102520. [Google Scholar] [CrossRef]
  75. Ghosh, I.; Jana, R.K. Clean energy stock price forecasting and response to macroeconomic variables: A novel framework using Facebook’s Prophet, NeuralProphet and explainable AI. Technol. Forecast. Soc. 2024, 200, 123148. [Google Scholar] [CrossRef]
  76. Suárez Gómez, S.L.; García Riesgo, F.; Pérez Fernández, S.; Iglesias Rodríguez, F.J.; Díez Alonso, E.; Santos Rodríguez, J.D.; De Cos Juez, F.J. Wavefront Recovery for Multiple Sun Regions in Solar SCAO Scenarios with Deep Learning Techniques. Mathematics 2023, 11, 1561. [Google Scholar] [CrossRef]
  77. Sanchez Lasheras, F.; Ordóñez, C.; Roca-Pardiñas, J.; de Cos Juez, F.J. Real-time tomographic reconstructor based on convolutional neural networks for solar observation. Math. Methods Appl. Sci. 2019, 43, 8032–8041. [Google Scholar] [CrossRef]
  78. Liu, Z.; Qian, S.; Xia, C.; Wang, C. Are transformer-based models more robust than CNN-based models? Neural Netw. 2024, 172, 106091. [Google Scholar] [CrossRef] [PubMed]
Figure 1. Gold metallurgy factory.
Figure 1. Gold metallurgy factory.
Mathematics 12 01039 g001
Figure 2. Illustration of the ε insensitive tube.
Figure 2. Illustration of the ε insensitive tube.
Mathematics 12 01039 g002
Figure 3. The COMEX gold spot price values, both observed and predicted, for three models: (a) Model 1 (NARX DE/SVR in the year 2019); (b) Model 2 (DE/GPR in the year 2019); and (c) Model 3 (DE/GPR in the year 2020).
Figure 3. The COMEX gold spot price values, both observed and predicted, for three models: (a) Model 1 (NARX DE/SVR in the year 2019); (b) Model 2 (DE/GPR in the year 2019); and (c) Model 3 (DE/GPR in the year 2020).
Mathematics 12 01039 g003
Table 1. The year 2019 MAPE error.
Table 1. The year 2019 MAPE error.
MethodDHRMDM
DE/SVR7.807.637.80
DE/GPR8.068.695.06
NARX DE/SVR7.616.725.92
NARX DE/GPR7.516.727.48
Table 2. The year 2020 MAPE error.
Table 2. The year 2020 MAPE error.
MethodDHRMDM
DE/SVR22.6020.6119.80
DE/GPR22.8221.8210.12
NARX DE/SVR20.7720.8622.94
NARX DE/GPR20.2320.4416.16
Table 3. The best models from the years 2019 and 2020.
Table 3. The best models from the years 2019 and 2020.
TypeYearOptimal Parameters
Model 1NARX DE/SVR2019 L a g = 5 ,   C = 9.2785 × 10 0
ε = 1.0297 × 10 0 ,   σ = 7.0995 × 10 3
Model 2DE/GPR2019 L a g = 4 ,   σ f 2 = 6.1384 × 10 5
l = 1.7375 × 10 1 ,   σ n 2 = 9.1358 × 10 5
Model 3DE/GPR2020 L a g = 5 ,   σ f 2 = 1.5520 × 10 5
l = 1.1629 × 10 0 ,   σ n 2 = 3.2258 × 10 2
Table 4. Accuracy of the best models.
Table 4. Accuracy of the best models.
ModelMAEMAPE (%)RMSER2
Model 183.8415.9292.7000.152
Model 273.6545.0695.8730.389
Model 3177.3210.12192.680.301
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

García-Gonzalo, E.; García-Nieto, P.J.; Fidalgo Valverde, G.; Riesgo Fernández, P.; Sánchez Lasheras, F.; Suárez Gómez, S.L. Hybrid DE-Optimized GPR and NARX/SVR Models for Forecasting Gold Spot Prices: A Case Study of the Global Commodities Market. Mathematics 2024, 12, 1039. https://doi.org/10.3390/math12071039

AMA Style

García-Gonzalo E, García-Nieto PJ, Fidalgo Valverde G, Riesgo Fernández P, Sánchez Lasheras F, Suárez Gómez SL. Hybrid DE-Optimized GPR and NARX/SVR Models for Forecasting Gold Spot Prices: A Case Study of the Global Commodities Market. Mathematics. 2024; 12(7):1039. https://doi.org/10.3390/math12071039

Chicago/Turabian Style

García-Gonzalo, Esperanza, Paulino José García-Nieto, Gregorio Fidalgo Valverde, Pedro Riesgo Fernández, Fernando Sánchez Lasheras, and Sergio Luis Suárez Gómez. 2024. "Hybrid DE-Optimized GPR and NARX/SVR Models for Forecasting Gold Spot Prices: A Case Study of the Global Commodities Market" Mathematics 12, no. 7: 1039. https://doi.org/10.3390/math12071039

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop