# An Empirical Study of Macroeconomic Factors and Stock Returns in the Context of Economic Uncertainty News Sentiment Using Machine Learning

Authors: Ayesha Jabeen; Muhammad Yasir; Yasmeen Ansari; Sadaf Yasmin; Jihoon Moon; Seungmin Rho
Journal: Complexity
 (2022)

---

## Abstract

Stock markets accurately reflect countries’ economic health, and stock returns are tightly related to economic indices. One popular area of financial research is the factors that influence stock returns. Several investigations have frequently cited macroeconomic factors, among numerous elements. Therefore, this study focuses on the empirical analysis of the relationship between macroeconomic factors and stock market returns. When a stock market becomes increasingly volatile, it becomes susceptible to economic uncertainty news, and information on social media platforms. Thus, we incorporated a new dimension of economic uncertainty news sentiment (EUNS) for stock return predictions. We employed the daily data ofgold index, crude oil price, interest rate, exchange rate, and stock returns for a set of countries from January 2010 to December 2020. Subsequently, to compute coefficients, we conducted a regression analysis using one of the more sophisticated approaches: single-layer neural networks and ordinary least square regression. In addition, we only computed EUNS for the period of the fiscal budget announcement for the US, Turkey, and Hong Kong. The results indicate that the gold index, interest rate, and exchange rate are highly significant and negative macroeconomic factors for all analyzed countries. These findings also indicate that EUNS is important and detrimental for projecting stock returns.


---

## Body

## 1. Introduction

In today’s global world, stock market performance is quite crucial for economic stability and growth. On the other hand, stock markets are also sensitive to economic conditions and uncertain events. Economists contend that the stock market is a leading indicator of economic growth. When the stock market does well, it indicates that the economy is working according to plan. For instance, it is indicated in existing studies that there have been positive influences on the economic growth of countries caused by the capitalization of stock markets [1]. Moreover, it has also been well-researched that several macroeconomic factors, business financial outcomes, and political events have a greater influence on stock markets [2]. Similarly, any economic news on various social media platforms, in either positive or negative terms, can also significantly influence stock markets [3, 4]. Stock market forecasting and analyses of stock returns under different factors have long been a classic but difficult research area, attracting the interest of both economists and computer scientists [5].The highly volatile nature of the stock market attracts researchers to explore the underlying factors that result in these movements. Moreover, investors must keep track of the key factors that affect stock returns. Investors need to pay attention to crucial macroeconomic indicators to earn optimal returns on their portfolios. Therefore, stock market prediction is very important for investors and policymakers [6]. In a financially risky marketplace, it is crucial to make very specific predictions about stock returns. Accurate stock prediction leads to market developments, guides investment strategies, and enlightens paths toward optimized stock trading. Stocks are considered one of the most sensitive assets in any economy [7]. Any aggressive variation in the stock market can negatively influence the economy. The main reasons for this risk are market irregularities, uncertainties, and volatility [8, 9]. In this context, stock forecasting tends to be a crucial task because fluctuations in the economy are sometimes quite drastic and sudden, which may lead to a fall in stock markets [10, 11].More specifically, various complicated economic factors and scenarios affect stock returns. Research indicates many key factors that affect share prices, including interest rates, exchange rates, company performances, political situations, current events, economic conditions, market psychology, natural disasters, and government policies [12–15]. Macroeconomic variables are theoretically considered the main source of stock volatility. Subsequently, these factors are the main indicators of stock returns [16]. These variables make stock prices unstable and challenging to anticipate with high precision. The existing literature includes many approaches suggested by various researchers for stock price prediction tasks. Some research studies have employed historical stock data on various stock markets to make predictions [17]. However, some studies have also employed social media analytics information, such as general sentiment, news, and sentiment regarding specific events [18], to conduct stock market analyses. More precisely, these events include the coronavirus disease 2019 (COVID-19) [19], the British exit from the European Union (Brexit) [20], and the 2019 Nigerian presidential election [21]. In both approaches, the social media-based analysis of big data regarding stocks has gained substantial attention over the past few years [18, 22] because this provides more clarity to investors for improved planning and decision-making. All these stock market prediction-related tasks have been accomplished using several approaches. Whenever any political or unpredictable event happens, it effects the stock market twofold. First, there is a direct effect on the economy because such events become the drivers of future economic and political policies. As a result of this set of policies, macroeconomic indicators fluctuate and affect the stock market [23]. Second, social media reaction to such events accelerates the impact on the stock market through the sentiment triggered by social media. In this context, it is inevitable to investigate the impact of macroeconomic indicators and social media sentiment on stock returns in special circumstances.Hence, the major research questions are the following: what if stock return analysis is performed using macroeconomic factors by employing the most sophisticated machine learning approaches (i.e., single-layer neural networks)? Second, what is the influence on the accuracy of stock returns if economic uncertainty news sentiment (EUNS) is incorporated alongside macroeconomic factors? Therefore, compared to the existing methods, this study provides a more in-depth stock market analysis given macroeconomic factors and EUNS using single-layer neural networks instead of traditional statistical and regression approaches. Furthermore, the existing studies[2, 24, 25] have analyzed the stock markets of a specific country in terms of macroeconomic factors, whereas this study assesses the stock markets of three well-established countries: Hong Kong, the US, and Turkey. We focus on four key macroeconomic factors, namely, the interest rate, crude oil price, exchange rate, and gold index to check their impact on stock returns for Turkish, Hong Kong, and US companies’ stock data. We collected the stock dataset from January 2010 to December 2020 to evaluate the model. We selected the top five performing stocks in these three stock markets based on their trading volume. Furthermore, to investigate the impact of social media sentiment, we constructed an index based on economic uncertainty news on Twitter. We extracted tweets from Twitter regarding certain keywords, namely, “foreign debt,” “trade balance,” “budget deficit,” “exchange rate depreciation,” “the law in order,” “war on terror,” “financial crisis,”“political instability,” “trade sanctions,” “financial sanction,” “turmoil period,” and “economic downtime.” This set of key words establishes an economic uncertainty news sentiment, which is later used as an independent variable to explain stock market returns. Subsequently, a single-layer neural network that is a time-series model is used to investigate the relationship between the exchange rate, interest rate, crude oil price, gold index, the sentiment of economic uncertainty, and stock returns. The contributions of this study are addressed below:(i)
A single-layer neural network is employed to investigate the influence of macroeconomic variables on stock returns, which is quite rare in this context.(ii)
We construct a Twitter sentiment of economic uncertainty news by applying textual analysis using a Twitter dataset.(iii)
We incorporate sentiments related to economic uncertainty news on Twitter into the model to explore their influence on stock returns in the US, Turkey, and Hong Kong.The remaining sections are arranged as follows: After the introduction, the Related Work section presents the literature review. The third section explains the methodology, and the fourth section reports the results and discussion, followed by the conclusion.


## 2. Related Work

In this section, we review the task of stock forecasting to examine stock market trends and discuss the literature on studies of the influence of macroeconomic variables on stock returns. This section also emphasizes the many methodologies used in stock market analysis.


### 2.1. Stock Market Analysis Using Traditional Methods

Examining the literature in terms of stock market analysis or forecasting tasks based on historical data on stock prices, Dash et al. proposed a fine-tuned version of support vector regression by applying grid search techniques to perform stock market predictions [26]. They validated their proposed model on eight different large stock datasets in various domains and attained better performance than existing methods. Similarly, Torres et al. proposed an algorithm based on random trees and the multilayer perceptron (MLP) methods to analyze Apple’s stock data [27]. The data employed in this study are also historical, and closing prices are predicted using machine learning algorithms. Ayala et al. [28] suggested several machine learning approaches, including linear regression, support vector regression, artificial neural networks (ANNs), and moving average-based methods. They tested the trading data from three indices which included Ibex35, DAX, and Dow Jones Industrial. Likewise, Mokhtari et al. [29] exploited machine learning approaches for stock market prediction in terms of buying, selling, and holding stocks. They performed both fundamental and technical analyses on the stock, along with feature selection and data-cleaning methods, to improve performance.


### 2.2. Stock Market Analysis Using Deep Learning Methods

Other than traditional machine learning methods, some researchers have also proposed deep learning-based advanced algorithms in the financial domain of stock data because these techniques perform well in diverse domains [30–32]. For example, Hiransha et al. [33] proposed four kinds of deep neural networks, namely, MLP, recurrent neural networks, long-short-term memory (LSTM) networks, and convolutional neural networks (CNNs) for stock market predictions using historical data. The stock data came from two stock exchanges: the National Stock Exchange of India and the New York Stock Exchange. Nikou et al. conducted a comparative study of machine learning and deep learning approaches for stock market predictions. The data in their study included the closing prices of the iShares MSCI United Kingdom exchange-traded fund. Their analysis observed that deep learning techniques work better than traditional machine learning approaches. Moghar and Hamiche suggested the LSTM model to predict future stock prices [34]. The primary goals of this study were to determine the precision with which a machine learning model can forecast and the number of epochs required to train a model. Sunny et al. [35] proposed a bidirectional LSTM model to predict the stock market. They validated their suggested model on publicly available datasets of stocks.


### 2.3. Stock Market Analysis with Sentiment Data

In contrast to the above-mentioned studies, some researchers have exploited the data based on sentiments to examine their influence on stock market predictions. For instance, Li et al. [36] incorporated stock prices and sentiments to perform stock predictions. Both sources of information were input into an LSTM model separately to estimate the stock return values. Jin et al. [10] involved investor sentiments in predicting stock prices by employing an attention-based LSTM model that focuses on more meaningful information. Furthermore, using empirical modal decomposition, they progressively deconstructed a complicated series of stock prices. Moreover, their results demonstrated that investors’ emotional tendencies are useful for improving expected outcomes. Additionally, the influence of certain mega-events, such as the COVID-19 pandemic, on various stock markets has also been analyzed. For instance, Lee [19] exploited the influence of COVID-19 on US stock markets. This study investigated whether the Daily News Sentiment Index forecasted US industrial returns differently by designing a regression model in which the dependent variable was the industry's excess returns.Gupta et al. [37] also suggested fusing historical data with sentiment data to accurately forecast the future of financial stocks. The model they designed is an LSTM model that best models the trends of future stock prices. The latest studies have also employed optimization-based methods combined with deep learning models to acquire more optimized values for stock prices during forecasting. For instance, Chung and Shin optimized architectural elements of the LSTM model, such as window size, with a genetic algorithm (GA) [38] because these structural elements play an important role in improving the performance of LSTM and ultimately significantly influence forecasting of stock prices. This study aimed to analyze the temporal characteristics of stock market data by proposing a structured technique for determining the time window size and architecture for the LSTM model. Similarly, Chung and Shin optimized the model topology using a GA; however, the underlying model was a CNN [39]. Their study indicated that a hybrid of CNN and GA outperformed the existing stock market prediction methods. Zhang et al. proposed a novel algorithm with the most advanced approach (i.e., generative adversarial networks with MLP as the discriminator model) that incorporates an LSTM model as a generator to predict stock prices [40]. The aim of the generator model built using LSTM was to extract the stock data distributions from the supplied stock data and then produce the same data, whereas the discriminator aims to differentiate between actual and generated stock data. Moreover, the latest research into stock trading and forecasting strategies exploits the application of deep reinforcement learning algorithms [41].


### 2.4. Analysis of Stock Returns with the Influence of Macroeconomic Variables

The mentioned studies conducted stock forecasting-related tasks using historical data, such as the open price of a stock and its high and low prices. However, these indicators are very basic because the stock market is quite sensitive and exposed to macroeconomic factors (e.g., the exchange rate, oil price, interest rate, and gold price) [42]. The effect of macroeconomic variables on the stock market is highly linear. The exchange rate of the stock market has a positive correlation with these external or macroeconomic variables, but this can vary between different markets and periods. Any general changes, such as foreign investment restrictions, induce changes to the stock market. Therefore, investigating the relationship between the stock exchange and macroeconomic variables is important [43]. In this respect, several pieces of research have been conducted to address the relationship between macroeconomic variables and stock market returns. Some have found a relationship between macroeconomic variables in the stock market, such as the real gross domestic product, aggregate price level, exchange rate, money supply, interest rate, and production index [44]. The interest rate, inflation, and money supply have a bidirectional relationship with stock returns [45]. News sentiments are also a significant variable when estimating stock market returns [46].Moreover, contradictory results are reported in the existing literature regarding the relationship between these variables. The relationship is quite dynamic and varies between countries [47]. Specifically, in the context of macroeconomic factors, Celebi and Hönig analyzed the German stock index in terms of the influence of macroeconomic factors [2]. They used data covering 27 years, and the results reported in this work indicate that many macroeconomic factors had a major influence on stock returns during pre-crisis and post-crisis times. Similarly, Omodero and Mlanga analyzed macroeconomic variables in Nigeria’s stock markets using the regression method [48]. Their investigation revealed that the exchange and interest rates have no substantial influence on the share price index. However, the inflation rate has a considerable detrimental influence on the share price index. Likewise, Ndlovu et al. [25] and J. Khan and I. Khan [24] worked on the stock exchanges of Johannesburg and Karachi to study the influence of macroeconomic variables. These studies involved several statistical analysis techniques and tests, such as the autoregressive distributed lag model, to examine the influence. Khan et al. observed that the money supply, exchange rate, and interest rate are essential macroeconomic variables that affect stock returns. In recent times, neural network models to investigate the relationship between macroeconomic variables and stock returns have been quite rare. Therefore, this study uses this model to empirically investigate the relationship between the gold index, crude oil price, interest rate, exchange rate, EUNS, and stock market returns.


## 2.1. Stock Market Analysis Using Traditional Methods

Examining the literature in terms of stock market analysis or forecasting tasks based on historical data on stock prices, Dash et al. proposed a fine-tuned version of support vector regression by applying grid search techniques to perform stock market predictions [26]. They validated their proposed model on eight different large stock datasets in various domains and attained better performance than existing methods. Similarly, Torres et al. proposed an algorithm based on random trees and the multilayer perceptron (MLP) methods to analyze Apple’s stock data [27]. The data employed in this study are also historical, and closing prices are predicted using machine learning algorithms. Ayala et al. [28] suggested several machine learning approaches, including linear regression, support vector regression, artificial neural networks (ANNs), and moving average-based methods. They tested the trading data from three indices which included Ibex35, DAX, and Dow Jones Industrial. Likewise, Mokhtari et al. [29] exploited machine learning approaches for stock market prediction in terms of buying, selling, and holding stocks. They performed both fundamental and technical analyses on the stock, along with feature selection and data-cleaning methods, to improve performance.


## 2.2. Stock Market Analysis Using Deep Learning Methods

Other than traditional machine learning methods, some researchers have also proposed deep learning-based advanced algorithms in the financial domain of stock data because these techniques perform well in diverse domains [30–32]. For example, Hiransha et al. [33] proposed four kinds of deep neural networks, namely, MLP, recurrent neural networks, long-short-term memory (LSTM) networks, and convolutional neural networks (CNNs) for stock market predictions using historical data. The stock data came from two stock exchanges: the National Stock Exchange of India and the New York Stock Exchange. Nikou et al. conducted a comparative study of machine learning and deep learning approaches for stock market predictions. The data in their study included the closing prices of the iShares MSCI United Kingdom exchange-traded fund. Their analysis observed that deep learning techniques work better than traditional machine learning approaches. Moghar and Hamiche suggested the LSTM model to predict future stock prices [34]. The primary goals of this study were to determine the precision with which a machine learning model can forecast and the number of epochs required to train a model. Sunny et al. [35] proposed a bidirectional LSTM model to predict the stock market. They validated their suggested model on publicly available datasets of stocks.


## 2.3. Stock Market Analysis with Sentiment Data

In contrast to the above-mentioned studies, some researchers have exploited the data based on sentiments to examine their influence on stock market predictions. For instance, Li et al. [36] incorporated stock prices and sentiments to perform stock predictions. Both sources of information were input into an LSTM model separately to estimate the stock return values. Jin et al. [10] involved investor sentiments in predicting stock prices by employing an attention-based LSTM model that focuses on more meaningful information. Furthermore, using empirical modal decomposition, they progressively deconstructed a complicated series of stock prices. Moreover, their results demonstrated that investors’ emotional tendencies are useful for improving expected outcomes. Additionally, the influence of certain mega-events, such as the COVID-19 pandemic, on various stock markets has also been analyzed. For instance, Lee [19] exploited the influence of COVID-19 on US stock markets. This study investigated whether the Daily News Sentiment Index forecasted US industrial returns differently by designing a regression model in which the dependent variable was the industry's excess returns.Gupta et al. [37] also suggested fusing historical data with sentiment data to accurately forecast the future of financial stocks. The model they designed is an LSTM model that best models the trends of future stock prices. The latest studies have also employed optimization-based methods combined with deep learning models to acquire more optimized values for stock prices during forecasting. For instance, Chung and Shin optimized architectural elements of the LSTM model, such as window size, with a genetic algorithm (GA) [38] because these structural elements play an important role in improving the performance of LSTM and ultimately significantly influence forecasting of stock prices. This study aimed to analyze the temporal characteristics of stock market data by proposing a structured technique for determining the time window size and architecture for the LSTM model. Similarly, Chung and Shin optimized the model topology using a GA; however, the underlying model was a CNN [39]. Their study indicated that a hybrid of CNN and GA outperformed the existing stock market prediction methods. Zhang et al. proposed a novel algorithm with the most advanced approach (i.e., generative adversarial networks with MLP as the discriminator model) that incorporates an LSTM model as a generator to predict stock prices [40]. The aim of the generator model built using LSTM was to extract the stock data distributions from the supplied stock data and then produce the same data, whereas the discriminator aims to differentiate between actual and generated stock data. Moreover, the latest research into stock trading and forecasting strategies exploits the application of deep reinforcement learning algorithms [41].


## 2.4. Analysis of Stock Returns with the Influence of Macroeconomic Variables

The mentioned studies conducted stock forecasting-related tasks using historical data, such as the open price of a stock and its high and low prices. However, these indicators are very basic because the stock market is quite sensitive and exposed to macroeconomic factors (e.g., the exchange rate, oil price, interest rate, and gold price) [42]. The effect of macroeconomic variables on the stock market is highly linear. The exchange rate of the stock market has a positive correlation with these external or macroeconomic variables, but this can vary between different markets and periods. Any general changes, such as foreign investment restrictions, induce changes to the stock market. Therefore, investigating the relationship between the stock exchange and macroeconomic variables is important [43]. In this respect, several pieces of research have been conducted to address the relationship between macroeconomic variables and stock market returns. Some have found a relationship between macroeconomic variables in the stock market, such as the real gross domestic product, aggregate price level, exchange rate, money supply, interest rate, and production index [44]. The interest rate, inflation, and money supply have a bidirectional relationship with stock returns [45]. News sentiments are also a significant variable when estimating stock market returns [46].Moreover, contradictory results are reported in the existing literature regarding the relationship between these variables. The relationship is quite dynamic and varies between countries [47]. Specifically, in the context of macroeconomic factors, Celebi and Hönig analyzed the German stock index in terms of the influence of macroeconomic factors [2]. They used data covering 27 years, and the results reported in this work indicate that many macroeconomic factors had a major influence on stock returns during pre-crisis and post-crisis times. Similarly, Omodero and Mlanga analyzed macroeconomic variables in Nigeria’s stock markets using the regression method [48]. Their investigation revealed that the exchange and interest rates have no substantial influence on the share price index. However, the inflation rate has a considerable detrimental influence on the share price index. Likewise, Ndlovu et al. [25] and J. Khan and I. Khan [24] worked on the stock exchanges of Johannesburg and Karachi to study the influence of macroeconomic variables. These studies involved several statistical analysis techniques and tests, such as the autoregressive distributed lag model, to examine the influence. Khan et al. observed that the money supply, exchange rate, and interest rate are essential macroeconomic variables that affect stock returns. In recent times, neural network models to investigate the relationship between macroeconomic variables and stock returns have been quite rare. Therefore, this study uses this model to empirically investigate the relationship between the gold index, crude oil price, interest rate, exchange rate, EUNS, and stock market returns.


## 3. Materials and Methods

This section elaborates on the dataset in this study and discusses the methodological steps to conduct the study. We describe the data collection procedure for analysis in the first stage and provide a step-by-step explanation to illustrate how the acquired data are used to study the influence of macroeconomic variables and EUNS on stock market returns for three nations. Figure1 depicts a representation of the methodology.Figure 1
Overview of the proposed methodology.


### 3.1. Data Collection

To assess the performance of the proposed model on historical stock data for technical analysis, we take daily data from the top five performing stocks in the Standard and Poor’s 500, the Hong Kong stock exchange, and the Borsa Istanbul stock exchange, as listed in Table1. Similarly, the currency rate, interest rate, gold price, and crude oil price are all considered to be macroeconomic variables. The data were acquired from January 2010 to December 2020. Subsequently, for the fundamental analysis, we employ sentiment analysis on tweets indexed against several keywords, including “foreign debt,” “trade balance,” “budget deficit,” “exchange rate depreciation,” “the law in order,” “war on terror financial crisis,” “political instability,” “trade sanctions,” “financial sanctions,” “turmoil period,” and “economic downtime.”Table 1
Set of countries and companies in the analysis.
CountriesTop companiesUnited NationsTurkeyHong KongAppleAK BankChina Merchant BankCiti GroupArcelikIndustrial and Commercial BankGeneral ElectricDogusPing Insurance CoMicrosoftKOC HoldingsHK IndexGoogleVestelUS IndexTurkey Index


### 3.2. Proposed Model for Technical and Fundamental Analyses of Stock and Sentiment Data with Macroeconomic Variables

After data acquisition, a model based on deep neural networks was designed to perform regression and estimate the coefficient values for macroeconomic variables and EUNS. Equations (1) and (2) compute the values of the coefficients.(1)Rτ=γ0−γ1Gi−γ2∗C0−γ3Ir−γ4Ex,(2)Rτ=γ0+γ1Gi+γ2Co+γ3Ir+γ4Ex+γ5S.In the above equations,Gi, Co, Ir, Ex, and S represent the gold price index, crude oil price, daily interest rate, exchange rate, and EUNS, respectively. Specifically, the neural network technique is used for the linear regression problem.Generally, linear regression refers to the set of problems in which we want to model the relationship between dependent and independent variables. This method is one of the most popular supervised machine learning algorithms in which the projected output is continuous and the slope indicates constant learning. Linear regression is classified into simple and multiple linear regression. Simple linear regression has only one independent variable and a bias term. However, multiple linear regression must have more than one independent variable. These regression problems can be formulated with the most sophisticated machine learning algorithms (i.e., ANNs). Also known as connectionist systems, these ANNs are inspired by the structure of the human brain and are very efficient approaches for designing predictive or regression models. These neural networks enable several machine learning algorithms to coordinate and handle complex inputs. Due to these characteristics, an algorithm can accomplish tasks, and the underlying algorithm is not usually designed with any task-specific rules. For instance, in computer vision, the system can perform image recognition and object detection in different domains [49, 50]. However, these tasks use the most advanced variants of ANNs (i.e., CNNs and object-detection models).In fact, ANNs are a strong tool for determining the association between input and output variables, which can be accomplished by training the ANNs on a large set of training records containing input and output data. Generally, the ANN architecture consists of units or nodes with weighted connections between them, where each unit introduces and conveys certain information to the network. This method works by first taking a vector of inputs, such asX=x1,x2,x3,…,xn, and generating a predictive model with the help of a mathematical function. In the next stage, the ANN starts learning by fine-tuning the weights present on connections between neurons, followed by measuring the model error, which is the difference between the projected model output and the actual values. This process is repeated many times or for a set number of epochs until it finds a model with an error near zero. Using ANNs, we can model any real-world problem because they are self-adaptive. They can be single-layer or multi-layer neural networks. We employed a single-layer network with only one input and one output layer to model the regression problem. A model is designed to take inputs of independent variables as a set and learn to find the best weights such that the value of the dependent variable and model outputs are nearly equal. In this case, these independent variables are macroeconomic variables’ sentiment values. We consider the following simple linear regression function, given in the following equation:(3)y=w0+w1x1+w2x2+w3x3,…,wnxn.In the above equation,x1, x2, x3, and xn are independent variables or features in a given input vector. In addition, w1, w2, w3, and wn are the coefficients and weights of the predictive model, and w0 is the bias term. The proposed architecture is divided into one input and one output layer. The number of units in the input layer equals the total number of independent variables, and the output layer has one unit. There are direct connections between every input and the output units and associated weights. The neural network optimizes these weights throughout every iteration using the Adam optimizer. This algorithm calculates the individual learning rates for different parameters. Moreover, to adapt the learning rates, the first and second moments of the gradient are also calculated for each coefficient or weight of the model. The expected value of the random variable is defined as its moment, as indicated in equation:(4)m=EXn.This random variable is used to represent the loss function of the neural network. Furthermore, after one iteration finishes, the weights or coefficients of the linear regression model are updated using the weight update equation described in equation (5) for all weights (i.e., w0, w1, w2, w3, and wn).(5)Wn=Wn−1−ηm^tv^t+ε,where Wn−1 is the value of the old weight, η is the step size, and the values of m^t and v^t, which represent the moments and variance, are calculated by equations (6) and (7), respectively.(6)m^t=mt1−β1t,(7)v^t=vt1−β2t,where β1 and β2 are the hyperparameters in equations (6) and (7), and equations (8) and (9) are used to calculate mt and vt.(8)mt=β1mt−1+1−β1gt,(9)vt=β2mt−2+1−β2gt2.The first moment is the meanmt, and the second moment is the variance vt. Furthermore, when the model converges and determines the best coefficients after updating the weights individually in every iteration, after the last iteration, the weights or coefficients are extracted and stored. The optimized loss function is the mean squared error function, defined as follows:(10)MSE=1N∑i=1nYi−Y^i2.In equation (10), N denotes the total number of instances in stock data, Yi is the actual value of the dependent variable, and Y^i represents the predicted value of the dependent variable. In the following stage, for each unobserved data point, we load the stored coefficients and multiply them by the relevant dependent variables to obtain the required value of the dependent variable. Figure 2 depicts the proposed model.Figure 2
Computation of coefficients for macroeconomic variables.


## 3.1. Data Collection

To assess the performance of the proposed model on historical stock data for technical analysis, we take daily data from the top five performing stocks in the Standard and Poor’s 500, the Hong Kong stock exchange, and the Borsa Istanbul stock exchange, as listed in Table1. Similarly, the currency rate, interest rate, gold price, and crude oil price are all considered to be macroeconomic variables. The data were acquired from January 2010 to December 2020. Subsequently, for the fundamental analysis, we employ sentiment analysis on tweets indexed against several keywords, including “foreign debt,” “trade balance,” “budget deficit,” “exchange rate depreciation,” “the law in order,” “war on terror financial crisis,” “political instability,” “trade sanctions,” “financial sanctions,” “turmoil period,” and “economic downtime.”Table 1
Set of countries and companies in the analysis.
CountriesTop companiesUnited NationsTurkeyHong KongAppleAK BankChina Merchant BankCiti GroupArcelikIndustrial and Commercial BankGeneral ElectricDogusPing Insurance CoMicrosoftKOC HoldingsHK IndexGoogleVestelUS IndexTurkey Index


## 3.2. Proposed Model for Technical and Fundamental Analyses of Stock and Sentiment Data with Macroeconomic Variables

After data acquisition, a model based on deep neural networks was designed to perform regression and estimate the coefficient values for macroeconomic variables and EUNS. Equations (1) and (2) compute the values of the coefficients.(1)Rτ=γ0−γ1Gi−γ2∗C0−γ3Ir−γ4Ex,(2)Rτ=γ0+γ1Gi+γ2Co+γ3Ir+γ4Ex+γ5S.In the above equations,Gi, Co, Ir, Ex, and S represent the gold price index, crude oil price, daily interest rate, exchange rate, and EUNS, respectively. Specifically, the neural network technique is used for the linear regression problem.Generally, linear regression refers to the set of problems in which we want to model the relationship between dependent and independent variables. This method is one of the most popular supervised machine learning algorithms in which the projected output is continuous and the slope indicates constant learning. Linear regression is classified into simple and multiple linear regression. Simple linear regression has only one independent variable and a bias term. However, multiple linear regression must have more than one independent variable. These regression problems can be formulated with the most sophisticated machine learning algorithms (i.e., ANNs). Also known as connectionist systems, these ANNs are inspired by the structure of the human brain and are very efficient approaches for designing predictive or regression models. These neural networks enable several machine learning algorithms to coordinate and handle complex inputs. Due to these characteristics, an algorithm can accomplish tasks, and the underlying algorithm is not usually designed with any task-specific rules. For instance, in computer vision, the system can perform image recognition and object detection in different domains [49, 50]. However, these tasks use the most advanced variants of ANNs (i.e., CNNs and object-detection models).In fact, ANNs are a strong tool for determining the association between input and output variables, which can be accomplished by training the ANNs on a large set of training records containing input and output data. Generally, the ANN architecture consists of units or nodes with weighted connections between them, where each unit introduces and conveys certain information to the network. This method works by first taking a vector of inputs, such asX=x1,x2,x3,…,xn, and generating a predictive model with the help of a mathematical function. In the next stage, the ANN starts learning by fine-tuning the weights present on connections between neurons, followed by measuring the model error, which is the difference between the projected model output and the actual values. This process is repeated many times or for a set number of epochs until it finds a model with an error near zero. Using ANNs, we can model any real-world problem because they are self-adaptive. They can be single-layer or multi-layer neural networks. We employed a single-layer network with only one input and one output layer to model the regression problem. A model is designed to take inputs of independent variables as a set and learn to find the best weights such that the value of the dependent variable and model outputs are nearly equal. In this case, these independent variables are macroeconomic variables’ sentiment values. We consider the following simple linear regression function, given in the following equation:(3)y=w0+w1x1+w2x2+w3x3,…,wnxn.In the above equation,x1, x2, x3, and xn are independent variables or features in a given input vector. In addition, w1, w2, w3, and wn are the coefficients and weights of the predictive model, and w0 is the bias term. The proposed architecture is divided into one input and one output layer. The number of units in the input layer equals the total number of independent variables, and the output layer has one unit. There are direct connections between every input and the output units and associated weights. The neural network optimizes these weights throughout every iteration using the Adam optimizer. This algorithm calculates the individual learning rates for different parameters. Moreover, to adapt the learning rates, the first and second moments of the gradient are also calculated for each coefficient or weight of the model. The expected value of the random variable is defined as its moment, as indicated in equation:(4)m=EXn.This random variable is used to represent the loss function of the neural network. Furthermore, after one iteration finishes, the weights or coefficients of the linear regression model are updated using the weight update equation described in equation (5) for all weights (i.e., w0, w1, w2, w3, and wn).(5)Wn=Wn−1−ηm^tv^t+ε,where Wn−1 is the value of the old weight, η is the step size, and the values of m^t and v^t, which represent the moments and variance, are calculated by equations (6) and (7), respectively.(6)m^t=mt1−β1t,(7)v^t=vt1−β2t,where β1 and β2 are the hyperparameters in equations (6) and (7), and equations (8) and (9) are used to calculate mt and vt.(8)mt=β1mt−1+1−β1gt,(9)vt=β2mt−2+1−β2gt2.The first moment is the meanmt, and the second moment is the variance vt. Furthermore, when the model converges and determines the best coefficients after updating the weights individually in every iteration, after the last iteration, the weights or coefficients are extracted and stored. The optimized loss function is the mean squared error function, defined as follows:(10)MSE=1N∑i=1nYi−Y^i2.In equation (10), N denotes the total number of instances in stock data, Yi is the actual value of the dependent variable, and Y^i represents the predicted value of the dependent variable. In the following stage, for each unobserved data point, we load the stored coefficients and multiply them by the relevant dependent variables to obtain the required value of the dependent variable. Figure 2 depicts the proposed model.Figure 2
Computation of coefficients for macroeconomic variables.


## 4. Results and Discussion

This section presents the results for all three selected countries (i.e., the US, Turkey, and Hong Kong) and a theoretical discussion. Subsequently, we compared existing studies regarding macroeconomic variable analysis with stock returns.


### 4.1. Analysis of Descriptive Statistics for Different Countries

Table2 lists the descriptive statistics for all macroeconomic variables for the US. The columns in Table 2 indicate all macroeconomic variables, and the rows display the mean, median, standard deviation, Jarque-Bera value, and a number of observations. Table 2 indicates how the Jarque-Bera test reveals that all variables follow non-normal distributions. The exchange rate has a very large Jarque-Bera test value for all variables. However, the mean values are 2.258, 0.582, 1.209, 69.321, and 17.365 for the index return, interest rate, exchange rate, crude oil price, and gold price, respectively. Moreover, the total number of observations for all variables is 2,750. In addition, the median values of the variables are 2.102, 0.463, 1.025, 56.321, and 15.963, and the standard deviation values are 0.0258, 0.862, 0.014, 0.254, and 0.372, in that order. The gold price index has greater fluctuations because its standard deviation is the highest of all variables.Table 2
Descriptive statistics for the United States.
VariablesIndex returnInterest rateExchange rateCrude oil priceGold price indexMean2.2580.5821.20969.32117.365Median2.1020.4631.02556.32115.963SD0.0260.8620.0140.2540.372Jarque-Bera68.225∗∗∗15.230∗∗∗85043.660∗∗∗36.925∗∗∗25.221∗∗∗Observations27502750275027502750∗∗∗∗denotes significance at 1% level.Table3 lists the descriptive statistics of variables for Turkey. Like the descriptive statistics for the US, the Jarque-Bera test demonstrates that all the variables follow a non-normal distribution. For the index return, interest rate, and exchange rate, the mean values are 1.258, 1.225, and 0.968; the standard deviations are 0.368, 0.124, and 0.0124; and the median values are 0.968, 1.102, and 0.752, respectively. The Jarque-Bera test result is greater for interest rates but lower for index returns.Table 3
Descriptive statistics for Turkey.
VariablesIndex returnInterest rateExchange rateMean1.2581.2250.968Median0.9681.1020.752SD0.3680.1240.012Jarque-Bera20.258∗∗∗39.639∗∗∗24.223∗∗∗Observations278027802780∗∗∗denotes significance at 1% level.Last, Table4 presents the descriptive statistics of variables, including the interest rate and exchange rate for Hong Kong. The Jarque-Bera test reveals that all these variables have a non-normal distribution. The exchange rate has the greatest Jarque-Bera value, and the index rate has the lowest. For the index return, interest rate, and exchange rate, the mean values are 2.368, 0.385, and 2.582. In addition, the standard deviation values are lower for all variables, including the index return, interest rate, and exchange rate, which indicate fewer fluctuations in the overall observations.Table 4
Descriptive statistics for Hong Kong.
VariablesIndex returnInterest rateExchange rateMean2.3680.3852.582Median1.9600.2252.301SD0.0120.0470.029Jarque-Bera22.369∗∗∗36.441∗∗∗890.228∗∗∗Observations280028002800∗∗∗denotes significance at 1% level.


### 4.2. Results with the Augmented Dickey-Fuller Unit Rate Test

If the number of observations is compared with the previous two nations, the overall number of observations for Hong Kong is greater than that for the US and Turkey. Generally, non-stationarity is a prevalent issue with time-series data. More explicitly, when the mean and standard deviation are time-dependent, it causes a “unit root problem.” The augmented Dickey-Fuller (ADF) test analyzes the unit root problem. The ADF test investigates the unit root hypothesis against the alternative of no unit root. When the problem of unit root exists, the data are considered nonstationary, causing bias in the estimated parameters. Table5 provides the results of the ADF test.Table 5
Unit rate test of different countries.
VariablesADF test (at level)ADF test (at 1st difference)Critical values at 5%CountriesCrude oil price−1.589−7.369∗∗∗−2.86Gold price index−2.458−12.367∗∗∗−2.86US Stock ReturnApple−72.045∗∗∗−2.86Citi Group−34.968∗∗∗−2.86General Electric−60.127∗∗∗−2.86Microsoft−72.840∗∗∗−2.86Google−58.635∗∗∗−2.86US Index Returns−52.360∗∗∗−2.86The USInterest rate−1.368−7.888∗∗∗−2.86Exchange rate−2.946−2.86Turkey Stock ReturnAK Bank−2.369−5.697∗∗∗−2.86Arcelik−3.895∗∗∗−2.86Dogus−12.360∗∗∗−2.86KOC Holdings−24.610∗∗∗−2.86Vestel−6.323∗∗∗−2.86Turkey Index−8.336∗∗∗−2.86TurkeyInterest rate−0.369∗∗∗−4.558∗∗∗−2.86Exchange rate−1.962−3.664∗∗∗−2.86Hong Kong Stock ReturnChina Merchant Bank−3.568∗∗∗−2.86Industrial and Commercial Bank−2.880∗∗−2.86Ping Insurance Co−12.336∗∗∗−2.86HK Index−7.813∗∗∗−2.86Hong KongInterest rate−1.367−4.360∗∗∗−2.86Exchange rate−2.301−9.361∗∗∗−2.86∗∗∗and ∗∗denote significance at the 1% and 5% levels, respectively; ADF: augmented Dickey-Fuller.The results indicate that most stock return data and exchange rates are stationary at the first level, whereas the interest rate, crude oil price, and gold index are stationary at the first difference. In Table5, the first column lists the variables. The second and third columns present the values of the ADF test with the first differences, whereas the last column displays the critical values at 5%. These values were computed for each country and their respective stock returns. Table 5 demonstrates that the critical values for all countries remain the same at −2.86. The ADF test (first difference) in the US for the crude oil price was −7.369 and for the gold price index was −12.367. Similarly, the value of the ADF test (the first difference between the interest and exchange rates) was −4.558 and −3.664 for Turkey; however, it was −4.360 and −9.361 for Hong Kong. The ADF test (first difference) for the exchange rate for Hong Kong was less than that of Turkey.The ADF test (at level) was also computed for each country and their respective stock returns. The macroeconomic variables of the exchange and interest rates for the US have ADF test (at level) values of about −2.946 and −1.368, respectively. Likewise, these respective values are −0.369 and −1.962 for Turkey and −1.367 and −2.301 for Hong Kong. Thus, this ADF test appropriately demonstrates the proper stationarity of time-series data for these nations.


### 4.3. Regression Results and Computation of Coefficients

To compute the regression results and calculate the coefficients, we used (1) to investigate the influence of macroeconomic variables, including the gold index (Gi), crude oil price (Co), interest rate (Ir), and exchange rate (Ex). Similarly, equation (2) investigates the influence of economic news (S) sentiment on stock returns for all countries. In the first stage, the influence of the gold index, crude oil price, interest rate, and the exchange rate was analyzed on the stock returns of the US stock market without involving the sentiment of the economic news (S). For this purpose, we used the stock returns of the top five performing companies along with the Standard and Poor’s 500 index. Table 6 lists the results for each country.Table 6
Coefficient outputs for the US without sentiment.
ParametersCompaniesγ0γ1γ2γ3γ4SLPApple0.0011−0.1133∗∗ (−2.6342)−0.1980 (−1.2358)−0.1194∗∗∗ (−3.5632)−0.2146∗ (−1.7523)Citi Group0.1487−0.0208∗∗ (−1.9730)−0.0044 (−1.0260)−0.0423∗∗∗ (−4.5320)−0.4389∗∗ (−2.3255)General Electric−0.0025−0.0893∗∗∗ (−3.6981)−0.1387∗ (−1.7283)−0.0713∗∗ (−2.0861)−0.1269∗∗∗ (−7.0036)Microsoft−0.0000−0.1417∗∗∗ (−12.5853)−0.0793 (−0.5581)−0.0931∗∗∗ (−3.2260)−0.0749∗∗ (−1.9931)Google−0.0009−0.1962∗∗∗ (−8.9680)−0.0217∗∗ (−2.0025)−0.1492∗∗∗ (−2.6089)−0.0034∗∗∗ (−2.7763)US Index0.0007−0.0995∗∗∗ (−10.8875)−0.1643∗∗ (−2.6987)−0.0804∗∗∗ (−3.8910)−0.1529∗∗∗ (−3.1250)OLSApple0.0032−0.0251 (−1.2365)−0.2153 (−0.9630)−0.1023∗∗ (−2.6980)−0.0126∗ (−1.6420)Citi Group0.1692−0.3654 (−1.3623)−0.0321 (−0.6980)−0.0214∗∗ (−2.3610)−0.3647 (−1.2045)General Electric−0.0030−0.0896∗∗∗ (−3.1250)−0.0032∗ (−1.6402)−0.0631 (−1.2561)−0.0378∗∗ (−2.1253)Microsoft−0.0003−0.1023∗∗ (−2.0021)−0.0032 (−1.236)−0.3680 (−1.2365)−0.2256 (−0.0023)Google−0.0036−0.1062∗∗ (−2.0125)−0.0361∗∗ (−2.5540)−0.3690∗∗ (−2.3600)−0.3265∗ (−1.6430)US Index0.0362−1.2632 (−6.5243)−0.3620 (−1.3620)−0.5326∗∗ (−2.3687)−0.2569∗∗ (−1.9682)∗∗∗, ∗∗, and ∗ indicate significance at the 1%, 5%, and 10% levels, respectively.Each column in Table6 provides the coefficient value for each macroeconomic variable. Moreover, the rows indicate the top five performing companies’ stock returns. For instance, in the case of the SLP (single-layer perceptron model), the coefficients of macroeconomic variables for Apple Company are 0.0011, −0.1133, −0.1980, −0.1194, and −0.2146. Similarly, Table 6 provides the values of coefficients for other companies also. The findings suggest that the influence of the gold index, oil price, interest rate, and exchange rate is highly significant and negative. As a result, any positive shock in the exchange rate causes stock returns to rise. Similarly, an increase in the gold index causes the stock return to decrease because the gold index is a relatively less risky option for investors. These results align with the existing literature (e.g., [51–54]). Subsequently, we employ equation (2) to investigate the influence of the gold index, crude oil price, interest rate, exchange rate, and sentiment of economic news on stock returns in the US stock market. For comparative analysis, we also report results of estimated coefficients based on OLS (Ordinary least square). All the coefficients are mostly negative and significant. However, the SLP model outperforms the OLS because most of the coefficients are highly significant, unlike the OLS.Table7 presents the results that include sentiment as another variable. Like Table 6, the columns indicate the coefficient values, including the coefficient of sentiment, and the rows indicate the companies. For instance, the first row provides the values of coefficients for Apple (i.e., −0.0003, −0.1164, −0.2797, 0.0737, −0.2751, and −0.0391).Table 7
Coefficient outputs for the US with sentiment.
ParametersCompaniesγ0γ1γ2γ3γ4γ5SLPApple−0.0003−0.1164∗ (−1.6842)−0.2797∗∗ (−2.2201)−0.0737∗∗∗ (−3.6128)−0.2751∗∗ (−2.6681)−0.0391∗∗∗ (−8.6680)Citi Group−0.4559−0.0178∗∗ (−2.0973)−0.0035 (−1.0260)−0.1832∗∗ (−2.5320)−0.1885 (−1.3255)−0.0654∗∗∗ (−3.225)General Electric0.00501−0.0036 (−0.7123)−0.0521∗ (−1.8283)−0.0101∗∗ (−2.0861)−0.0335∗∗∗ (−7.0036)−0.1026∗∗ (−10.5638)Microsoft0.0089−0.0020∗∗∗ (−12.5853)−0.1756 (−0.5581)−0.0646∗∗∗ (−3.2260)−0.2097∗∗ (−1.9931)−0.0068∗∗ (−2.8969)Google0.0029−0.0116∗ (−1.9080)−0.0968 (−1.0025)−0.0019∗∗∗ (−3.6157)−0.09032∗∗ (−2.0563)−0.0769∗∗∗ (−5.8801)US Index−0.0007−0.0550∗ (−1.7675)−0.2368∗ (−1.6987)−0.0142∗∗∗ (−3.8910)−0.2369∗∗ (−2.1250)−0.1199∗∗ (−2.3601)OLSApple−0.0023−0.0012∗∗ (−2.0360)−0.1578∗ (−1.6890)−0.0589∗∗∗ (−3.5580)−0.2875∗∗ (−2.3690)−0.6890∗∗∗ (−6.3281)Citi Group−0.0036−0.3482∗ (−1.6480)−0.1258 (−0.3670)−0.3470∗∗ (−2.3600)−0.1244 (−0.7820)−0.0224∗ (−1.8950)General Electric0.3600−0.0125 (−0.0367)−0.0362∗ (−1.6432)−0.0125∗ (−1.6980)0.7785∗∗∗ (3.6650)−0.4457∗∗∗ (−6.3325)Microsoft0.0025−0.0480∗∗ (−7.6380)−0.7412 (−0.4450)−0.0889∗∗ −(2.2236)−0.2287 (−0.3668)−0.0560 (−1.3580)Google0.0235−0.2258 (−1.4480)−0.0036 (−0.4412)−0.4521 (−1.0231)−0.4425∗∗ (−1.9632)−0.0125∗∗∗ (−3.1425)US Index−0.0034−0.0142 (−1.2365)−0.0147 (−1.5243)−0.1252∗ (−1.7630)−0.1425∗∗ (−2.5630)−0.2250∗∗(−2.1125)∗∗∗, ∗∗, and ∗ indicate significance at the 1%, 5%, and 10% levels, respectively.Likewise, the subsequent rows provide the coefficient values for the remaining companies under US stock returns. The findings suggest that the gold index, interest rate, and exchange rate have highly significant and negative influences. All the coefficients of these variables are negatively significant at the 1% level, and any positive shock in the exchange rate causes the stock returns to increase. The coefficient of social media sentiment toward economic news is highly significant and negative at the 5% and 1% significance levels. The statistical significance of the EUNS indicates that during the period of a fiscal budget announcement, any economic uncertainty news negatively influences stock returns. For comparative analysis, we also report results of estimated coefficients based on OLS (ordinary least square). All the coefficients are mostly negative and significant. However, the SLP model outperforms the OLS because most of the coefficients are highly significant, unlike the OLS.In the second experiment, we assessed the values of coefficients for Turkey with two experimental settings. In the first setting, we used (1) to investigate the influence of the gold index, crude oil price, interest rate, and exchange rate on stock returns in the Turkish stock market without including sentiment as a variable. We used the stock returns of the top five performing firms and the BIST 100 index. Table 8 presents the findings. The columns in Table 8 indicate the coefficients, and the rows indicate the selected firms.Table 8
Coefficients outputs for Turkey without sentiment.
ParametersCompaniesγ0γ1γ2γ3γ4SLPAK Bank−0.7458−0.1942∗ (−1.8251)0.0308 (0.3680)−0.0794∗∗ (−2.6687)−0.0104∗∗∗ (−3.6897)Arcelik0.0015−0.0818 (−1.0021)0.0595∗ (0.2421)−0.0194∗∗∗ (−3.2258)−0.1275∗∗∗ (−6.3360)Dogus−0.0045−0.0053 (−1.2253)−0.0081 (−0.0225)−0.0042∗∗ (−2.021)0.0085∗∗∗ (−5.4420)KOC Holdings0.0003−0.0586 (−1.5581)0.0790 (1.0258)−0.1313∗∗ (−1.9980)−0.0181∗ (−1.8412)Vestel−0.0013−0.0672 (−1.3760)−0.0659 (−0.9985)−0.0202∗∗∗ (−6.2213)−0.1177∗∗∗ (−8.6601)Turkey Index−0.0017−0.0668 (−0.8962)0.1446 (0.0258)−0.1187∗∗ (−2.6621)−0.0128∗∗ (−2.0170)OLSAK Bank−0.2563−0.0124 (−1.6347)0.5692∗∗ (2.3610)0.0365 (1.3481)−1.3650∗∗ (−2.5560)Arcelik0.0012−1.4458 (−1.5520)0.0523 (0.0030)−0.0365∗ (−1.8963)−1.2480∗∗ (−2.4120)Dogus−0.2570−0.0124 (−0.2250)−0.1240 (−0.7890)−0.1022 (−1.3580)−0.3658∗∗∗ (−3.6558)KOC Holdings0.0014−0.0124 (−1.3560)0.0124 (1.3610)−0.1245∗ (−1.8860)−0.0115 (−1.5520)Vestel0.0036−0.0023 (−0.1258)−0.2568 (−0.3480)−0.2540 (−0.4580)−0.1024∗∗ (−2.5580)Turkey Index0.3152−0.0558 (−0.4280)1.4580∗ (1.8320)−0.0530∗ (−1.9680)−0.9630∗∗ (−2.4520)∗∗∗, ∗∗, and ∗ indicate significance at the 1%, 5%, and 10% levels.These firms are AK Bank, Arcelik, Dogus, KOC Holdings, Vestel, and Turkey Index. More explicitly, the values of coefficients for AK Bank are −0.7458, 0.0015, −0.0045, 0.0003, −0.0013, and −0.0017. Similarly, for Arcelik, the values of coefficients are 0.0015, −0.0818, 0.0595, −0.0194, and 0.1275. Subsequently, the remaining rows of Table8 present the values of coefficients for the remaining top five firms in Turkey. According to the results, the coefficients for the interest and exchange rates are extremely significant and negative. Any positive shock in the exchange rate leads to increased stock returns. Similarly, an increase in the interest rate causes stock returns to decrease. However, the crude oil price and gold index are insignificant. These findings are similar to the results reported by Toparlı et al. [55] in the context of Turkey using the time-varying parameter vector autoregressive approach. For comparative analysis, we also report results of estimated coefficients based on OLS (Ordinary least square). All the coefficients are mostly negative and significant. However, the SLP model outperforms the OLS because most of the coefficients are highly significant, unlike the OLS.In the second experimental setting, we used equation (2) to investigate the influence of the gold index, crude oil price, interest rate, exchange rate, and the additional variable of the sentiment of economic news on stock returns for the Turkish stock market. Table 9 displays the results for this experimental setting. The columns in Table 9 indicate the coefficients from γ° to γ5, including the sentiment variable. The rows list the values of the top five firms in Turkey, as given in the previous experimental setting. Our findings suggest that the gold index, interest rate, and exchange rate have highly significant and negative influences. All the coefficients of these variables are negatively significant at the 1% level. An increase in the price of the gold index becomes attractive for investors, which negatively influences stock returns. Any positive shock in the exchange rate causes the stocks’ returns to increase. The coefficient of EUNS is highly significant and negative, indicating that any economic uncertainty news negatively influences stock returns during the period leading up to the fiscal budget release. For comparative analysis, we also report results of estimated coefficients based on OLS (ordinary least square). All the coefficients are mostly negative and significant. However, the SLP model outperforms the OLS because most of the coefficients are highly significant, unlike the OLS.Table 9
Coefficient outputs for Turkey with sentiment.
ParametersCompaniesγ0γ1γ2γ3γ4γ5SLPAK Bank−0.5609−0.0328 (−1.3694)−0.0448 (−0.3325)−0.0016∗∗ (−2.5821)−0.0123∗∗∗ (−5.3368)−0.4417∗∗∗ (−7.3621)Arcelik0.0009−0.0123∗∗ (−2.3324)0.0001 (1.0025)−0.0068∗∗ (−2.3369)−0.0037∗∗∗ (−7.9980)−0.1147∗∗ (−2.0178)Dogus−0.0053−0.0094∗∗∗ (−3.6687)−0.0142 (−0.2258)−0.0020∗∗∗ (−3.1201)−0.0082∗∗∗ (−2.9836)−0.0081∗∗∗ (−3.6612)KOC Holdings−0.0025−0.0186∗∗∗ (−4.6674)−0.0031 (−1.6237)−0.0102∗∗ (−1.9932)−0.0023∗∗∗ (−12.3546)−0.1057∗∗∗ (−8.3691)Vestel0.0034−0.0150∗∗∗ (−12.9986)−0.0027 (−0.0089)−0.0088∗ (−1.6794)−0.0071∗∗∗ (−3.2257)−0.0947∗∗ (−2.6389)Turkey Index−0.0028−0.0393∗∗∗ (−16.2258)0.0066 (1.0028)−0.0226∗∗∗ (−3.2292)−0.0068∗ (−4.5528)−0.1636∗∗∗ (−3.2630)OLSAK Bank−0.5630−0.5230 (−1.4030)−0.4236 (−0.8632)−1.7410∗ (−1.8820)−0.1423∗∗∗ (−3.7430)−0.4620∗∗∗ (−6.9930)Arcelik0.0742−0.4620∗ (−1.9630)−0.1456 (−0.4310)−0.1036∗∗ (−2.2310)−0.4250∗∗∗ (−4.8632)−0.4520∗ (−1.8850)Dogus0.0042−0.0467∗∗ (−2.4520)−0.4460 (−0.3336)−0.0325∗∗ (−1.996)−0.3460 (−1.4630)−0.2200 (−1.3870)KOC Holdings0.3360−0.7630∗∗∗ (−3.6690)−0.3340 (−0.6980)−0.0111 (−1.4520)−0.0021∗∗∗ (−7.6460)−0.0364∗∗∗ (−3.6540)Vestel0.4560−0.7520 (−1.6280)−0.0240 (−0.4420)−0.3360 (−1.3120)−0.1270∗∗ (−2.4630)−0.1860 (−1.4850)Turkey Index−0.1120−0.0125∗∗∗ (−6.2240)0.0460 (0.4430)−0.3640∗∗ (−2.1360)0.0125∗∗ (−2.3120)−0.1240 (1.4560)∗∗∗, ∗∗, and ∗ indicate significance at the 1%, 5%, and 10% levels, respectively.In the last experiment, we estimated the values of coefficients for Hong Kong. This experiment was also divided into two scenarios. In the first, we used (1) to investigate the influence of the gold index, crude oil price, interest rate, and exchange rate on stock returns in the Hong Kong stock market without involving the sentiment variable. To accomplish this, we used the stock returns of the top five performing companies alongside the Hong Kong stock exchange index. Table 10 presents the results of this experimental scenario.Table 10
Coefficient outputs for Hong Kong without sentiment.
ParametersCompaniesγ0γ1γ2γ3γ4SLPChina Merchant Bank−0.2290−0.1439 (−0.2548)−0.0030∗∗ (−2.0145)−0.0259∗∗ (−2.3684)−0.2028∗∗∗ (−3.0125)Industrial and Commercial Bank0.6643−0.4067 (−1.3582)−0.0082∗∗ (−2.8560)−0.0736∗∗ (−1.9984)−0.5098∗∗ (−2.1584)Ping Insurance co−0.6343−0.2024∗ (−1.7837)−0.0023∗∗ (−2.3689)−0.0268∗∗∗ (−3.2514)−0.2131∗∗∗ (−3.5562)HK Index−0.0008−0.1593∗ (−1.8920)−0.1876∗∗ (−2.0258)−0.0792∗ (−2.5218)−0.1759∗∗ (−1.9725)OLSChina Merchant Bank−0.0210−0.2350 (−0.4610)−0.0412 (−1.6310)−0.0145∗ (−1.7820)−0.1048∗∗ (−2.1050)Industrial and Commercial Bank0.4420−0.0230 (−0.2250)0.1205∗ (−1.6630)−0.3660 (−0.8960)0.5520 (1.4420)Ping Insurance Co.−0.3360−0.1020 (−1.0020)−0.1254∗∗ (−1.9980)−0.3360∗∗ (−2.2630)−0.3360∗ (−1.8820)HK Index0.2250−0.2236 (−1.3650)−0.3360∗ (−1.6630)−0.4450∗∗ (−2.2540)−0.4420∗ (−1.6880)∗∗∗, ∗∗, and ∗ indicate significance at the 1%, 5%, and 10% levels, respectively.The columns in Table10 display the values of the coefficients, and the rows indicate the top three companies in Hong Kong: China Merchant Bank, Industrial Commercial Bank, Ping Insurance Co., and HK Index. Table 9 indicates that the coefficient values of the China Merchant Bank are −0.229, −0.1439, −0.0030, −0.0259, and −0.2028. Likewise, the coefficient values of the Industrial and Commercial banks are −0.229, −0.1439, −0.0030, −0.0259, and −0.2028. Likewise, the coefficient values of the Industrial and Commercial banks are −0.6643, −0.4067, −0.0082, −0.0736, and −0.5098. These findings suggest that the crude oil price, interest rate, and exchange rate are highly significant and negatively influenced. All coefficients of these variables are negatively significant at either the 5% or 1% significance levels. Any positive shock in the exchange rate causes the stocks' returns to increase. These results are similar to those of Khan et al. [56], who reported that the oil price negatively influences stock returns in the short and long run. For comparative analysis, we also report results of estimated coefficients based on OLS (ordinary least square). All the coefficients are mostly negative and significant. However, the SLP model outperforms the OLS because most of the coefficients are highly significant, unlike the OLS.In the next scenario, we employ equation (2) to investigate the influence of the gold index, crude oil price, interest rate, and exchange rate by including the sentiment of economic news on stock returns in the Hong Kong stock market. Table 11 provides the results of this scenario for Hong Kong.Table 11
Coefficient outputs for Hong Kong with sentiment.
ParametersCompaniesγ0γ1γ2γ3γ4γ5SLPChina Merchant Bank−0.0184−0.0958∗ (−12.3360)−0.0036 (−0.3368)−0.0193∗∗ (−2.0588)−0.1512∗ (−1.9018)−0.0428∗∗∗ (−5.8862)Industrial and Commercial Bank−0.0259−0.0589∗ (−5.2261)−0.0086 (−0.8962)−0.0197∗∗∗ (−3.2258)−0.1119∗∗ (−2.5581)−0.6913∗∗∗ (−6.3542)Ping Insurance Co0.4591−0.1638∗∗ (−2.5120)−0.0027 (−1.2250)−0.0238∗∗∗ (−2.8960)−0.1813∗∗ (−5.2285)−0.3442∗∗∗ (−4.3325)HK Index0.0062−0.0032∗∗∗ (−7.8891)−0.0239∗ (−1.8251)−0.0501∗∗∗ (−4.5520)−0.0237∗ (−13.2884)−0.1295∗∗∗ (−7.2258)OLSChina Merchant Bank−0.0125−0.0456∗∗∗ (−4.6320)−0.0653 (−0.0021)−0.2350 (−1.3350)−0.1020 (−1.0050)−0.4580∗∗ (−2.4420)Industrial and Commercial Bank−0.8630−0.0030∗ (−1.8060)−0.0032 (−0.0056)−0.1120∗∗ (−2.3660)−0.1130 (−0.3340)−0.4460∗∗∗ (−3.5620)Ping Insurance Co0.5560−0.0040 (−1.2050)0.1120 (0.6670)−0.5520 (−0.0780)−0.1140∗ (−1.6680)−0.0050∗∗ (−2.1220)HK Index0.3360−0.0010∗ (−1.6640)0.4450 (0.6680)−0.4380 (−0.4450)−0.0052∗ (−2.1100)0.5630∗∗ (−2.0050)∗∗∗, ∗∗, and ∗ indicate significance at the 1%, 5%, and 10% levels, respectively.The effects of the gold index, interest rate, and exchange rate are highly significant and negative. All the coefficients of these variables are negatively significant at the 1% level. Any positive shock in the exchange rate increases the stock returns. The coefficient of social media sentiment toward economic news is highly significant and negative. Thus, during the period of a fiscal budget announcement, any economic uncertainty news negatively affects stock returns. For comparative analysis, we also report results of estimated coefficients based on OLS (ordinary least square). All the coefficients are mostly negative and significant. However, the SLP model outperforms the OLS because most of the coefficients are highly significant, unlike the OLS.


### 4.4. Results of Predictions with Macroeconomic Factors and without Sentiment

In this section, we analyze the performance of the proposed model in terms of predicting the returns of different companies in the US, Turkey, and Hong Kong. In the first step, we tested the models using macroeconomic factors without including sentiment. We trained the single-layer perceptron model using macroeconomic variables such as the exchange rate, interest rate, gold index, and oil price across 50 epochs. In regression, these variables are regarded as dependent variables, whereas the target variable is the returns of various companies.The parameters of a single-layer perceptron include the weight optimizer, which is Adam; the loss function is “Mean Squared Error,” and the batch size is 4. The input layer of a single-layer neural network consists of units equal to dependent variables, while the last consists of one unit (neuron) representing the output value. Figure3 depicts the MSE loss during single-layer neural network training for enterprises from all nations. The first graph illustrates the training loss on the data of all Hong Kong companies, whereas the second graph depicts loss curves on US companies, and the third graph depicts curves on Turkish companies. The graphs show that a single-layer neural network converges quite smoothly and with near-zero error.Figure 3
Training loss curves of the companies of different countries including Hong Kong, the United States, and Turkey without sentiments.In addition, we have computed the values of RMSE (root mean square error), MAE (mean absolute error), and MSE (mean squared error) to evaluate the robustness or performance of single-layer perceptrons and the OLS method. Table12 shows the values of RMSE, MSE, and MAE for companies in Hong Kong, the US, and Turkey with single-layer perceptron. Each part of Table 12 shows the results of different companies. These scores are computed by using the actual and predicted values of returns. It is observed from Table 12 that values of RMSE, MSE, and MAE are quite low, which is an indication of best performance.Table 12
Results of single layer perceptron for all companies of Hong Kong, the US, and Turkey without sentiment.
Results of single-layer perceptronRMSEMSEMAEHong KongHK Index0.06700.00450.0450Ping Insurance Co0.06640.00440.0473Industrial and Commercial Bank0.09860.00970.0680China Merchant Bank0.07870.00620.0570United StatesUS Index0.05550.00310.0327Microsoft0.05520.00300.0366Google0.05890.00350.0409General Electric0.06230.00390.0411Citi Group0.22760.05180.1730Apple0.07060.00500.0495TurkeyBIST index0.04150.00170.0041Vestel0.07090.00500.0469KOC Holdings0.07960.00630.0573Dogus0.04990.00250.0211AK Bank0.10130.01030.0746Arcelik0.09620.00930.0684However, AK Bank of Turkey's RMSE score is slightly higher when compared to companies from other countries. In addition, for comparison, we repeated the same experiments using the OLS method as shown in Table13. It is observed from Table 13 that the values of RMSE, MSE, and MAE with the OLS technique are generally the same as with the SLP method. However, for certain companies, the values of error with the OLS approach are higher than with the SLP approach, which demonstrates the feasibility of ANN-based approaches. Furthermore, the SLP is currently based on single-layer, but performance improves when the depth is increased to multi-layers to capture more information from features. The smallest loss values also reflect another realisable value: that predictions become more accurate when macroeconomic factors are considered.Table 13
Results of OLS method for all companies of Hong Kong, US, and Turkey without sentiments.
Results of OLSRMSEMSEMAEHong KongHK Index0.07310.00530.0479Ping Insurance co0.07400.00550.0055Industrial and Commercial Bank0.08180.00670.0589China Merchant Bank0.08140.00660.0592United StatesUS Index0.04560.00210.0304Microsoft0.05190.00270.0375Google0.05820.00340.0407General Electric0.06590.00430.0451Citi Group0.23050.05310.1754Apple0.06890.00480.0477TurkeyBIST Index0.00331.10120.0024Vestel0.06000.00360.0396KOC Holdings0.08150.00660.0594Dogus0.05130.00260.0180AK Bank0.10160.01030.0757Arcelik0.08900.00790.0636


### 4.5. Results of Predictions with Macroeconomic Factors and Sentiment

We evaluated the model's performance in the second stage by including both sentiments and macroeconomic factors. In this experimental setting, the variables of linear regression include the exchange rate, interest rate, gold index, crude oil prices, and sentiment variable. We trained the single-layer perceptron model with these variables for 50 epochs and performed the task of prediction. All of these experiments are repeated with firms from other countries. The training loss curves of different experiments are depicted in Figure4.Figure 4
Training loss curves of the companies of different countries including Hong Kong, Turkey, and the United States with sentiments.The first graph shows the loss curves of Hong Kong companies, the second graph shows the results of Turkey’s companies, and the last graph shows the loss curves of the United Nation's companies. Graphs show that SLP models converge relatively rapidly and loss values reach zero. In addition, the results in the form of RMSE, MSE, and MAE of SLP models with the companies of all countries are also computed as given in Table14. Table 14 contains the findings of companies from various countries. These results are computed by combining actual and predicted return values. Table 14 shows that the values of RMSE, MSE, and MAE are relatively low, indicating excellent performance. As shown in Table 15, we also assessed and extracted the performance of both macroeconomic factors and sentiments using the standard linear regression approach. It has been noticed that the error values with SLP employing sentiments are better than the OLS approach; for example, the MSE value of SLP is 1.10, while the MSE value of OLS is 1.26, which is more than SLP. As a result, it is logically stated that macroeconomic factors and sentiments have a significant effect on returns.Table 14
Results of the SLP method for all companies of Hong Kong, US, and Turkey with sentiments.
Results of single-layer perceptronRMSEMSEMAEHong KongHK Index0.07230.00520.0541Ping Insurance co0.06890.00470.0495Industrial and Commercial Bank0.08730.00760.0653China Merchant Bank0.08590.00740.0633United StatesUS Index0.05460.00300.0333Microsoft0.05670.00320.0380Google0.05470.00300.0394General Electric0.06060.00370.0409Citi Group0.00121.45640.0008Apple0.07670.00590.0524TurkeyBIST Index0.00361.26060.0026Vestel0.06700.00450.0470KOC Holdings0.08070.00650.0631Dogus0.06140.00380.0215AK Bank0.11020.01220.0858Arcelik0.08970.00800.0673Table 15
Results of OLS method for all companies of Hong Kong, US, and Turkey with sentiments.
Results of OLSRMSEMSEMAEHong KongHK Index0.07840.00620.0584Ping Insurance Co0.07730.00600.0541Industrial and Commercial Bank0.08520.00730.0639China Merchant Bank0.07990.00640.0595United StatesUS Index0.04790.00230.0319Microsoft0.05070.00260.0368Google0.05990.00360.0414General Electric0.05970.00360.0415Citi Group0.04290.00180.0022Apple0.07170.00510.0496TurkeyBIST Index0.00341.16080.0025Vestel0.07560.00570.0511KOC Holdings0.08280.00690.0645Dogus0.05200.00270.0228AK Bank0.10720.01150.0844Arcelik0.08650.00750.0673


## 4.1. Analysis of Descriptive Statistics for Different Countries

Table2 lists the descriptive statistics for all macroeconomic variables for the US. The columns in Table 2 indicate all macroeconomic variables, and the rows display the mean, median, standard deviation, Jarque-Bera value, and a number of observations. Table 2 indicates how the Jarque-Bera test reveals that all variables follow non-normal distributions. The exchange rate has a very large Jarque-Bera test value for all variables. However, the mean values are 2.258, 0.582, 1.209, 69.321, and 17.365 for the index return, interest rate, exchange rate, crude oil price, and gold price, respectively. Moreover, the total number of observations for all variables is 2,750. In addition, the median values of the variables are 2.102, 0.463, 1.025, 56.321, and 15.963, and the standard deviation values are 0.0258, 0.862, 0.014, 0.254, and 0.372, in that order. The gold price index has greater fluctuations because its standard deviation is the highest of all variables.Table 2
Descriptive statistics for the United States.
VariablesIndex returnInterest rateExchange rateCrude oil priceGold price indexMean2.2580.5821.20969.32117.365Median2.1020.4631.02556.32115.963SD0.0260.8620.0140.2540.372Jarque-Bera68.225∗∗∗15.230∗∗∗85043.660∗∗∗36.925∗∗∗25.221∗∗∗Observations27502750275027502750∗∗∗∗denotes significance at 1% level.Table3 lists the descriptive statistics of variables for Turkey. Like the descriptive statistics for the US, the Jarque-Bera test demonstrates that all the variables follow a non-normal distribution. For the index return, interest rate, and exchange rate, the mean values are 1.258, 1.225, and 0.968; the standard deviations are 0.368, 0.124, and 0.0124; and the median values are 0.968, 1.102, and 0.752, respectively. The Jarque-Bera test result is greater for interest rates but lower for index returns.Table 3
Descriptive statistics for Turkey.
VariablesIndex returnInterest rateExchange rateMean1.2581.2250.968Median0.9681.1020.752SD0.3680.1240.012Jarque-Bera20.258∗∗∗39.639∗∗∗24.223∗∗∗Observations278027802780∗∗∗denotes significance at 1% level.Last, Table4 presents the descriptive statistics of variables, including the interest rate and exchange rate for Hong Kong. The Jarque-Bera test reveals that all these variables have a non-normal distribution. The exchange rate has the greatest Jarque-Bera value, and the index rate has the lowest. For the index return, interest rate, and exchange rate, the mean values are 2.368, 0.385, and 2.582. In addition, the standard deviation values are lower for all variables, including the index return, interest rate, and exchange rate, which indicate fewer fluctuations in the overall observations.Table 4
Descriptive statistics for Hong Kong.
VariablesIndex returnInterest rateExchange rateMean2.3680.3852.582Median1.9600.2252.301SD0.0120.0470.029Jarque-Bera22.369∗∗∗36.441∗∗∗890.228∗∗∗Observations280028002800∗∗∗denotes significance at 1% level.


## 4.2. Results with the Augmented Dickey-Fuller Unit Rate Test

If the number of observations is compared with the previous two nations, the overall number of observations for Hong Kong is greater than that for the US and Turkey. Generally, non-stationarity is a prevalent issue with time-series data. More explicitly, when the mean and standard deviation are time-dependent, it causes a “unit root problem.” The augmented Dickey-Fuller (ADF) test analyzes the unit root problem. The ADF test investigates the unit root hypothesis against the alternative of no unit root. When the problem of unit root exists, the data are considered nonstationary, causing bias in the estimated parameters. Table5 provides the results of the ADF test.Table 5
Unit rate test of different countries.
VariablesADF test (at level)ADF test (at 1st difference)Critical values at 5%CountriesCrude oil price−1.589−7.369∗∗∗−2.86Gold price index−2.458−12.367∗∗∗−2.86US Stock ReturnApple−72.045∗∗∗−2.86Citi Group−34.968∗∗∗−2.86General Electric−60.127∗∗∗−2.86Microsoft−72.840∗∗∗−2.86Google−58.635∗∗∗−2.86US Index Returns−52.360∗∗∗−2.86The USInterest rate−1.368−7.888∗∗∗−2.86Exchange rate−2.946−2.86Turkey Stock ReturnAK Bank−2.369−5.697∗∗∗−2.86Arcelik−3.895∗∗∗−2.86Dogus−12.360∗∗∗−2.86KOC Holdings−24.610∗∗∗−2.86Vestel−6.323∗∗∗−2.86Turkey Index−8.336∗∗∗−2.86TurkeyInterest rate−0.369∗∗∗−4.558∗∗∗−2.86Exchange rate−1.962−3.664∗∗∗−2.86Hong Kong Stock ReturnChina Merchant Bank−3.568∗∗∗−2.86Industrial and Commercial Bank−2.880∗∗−2.86Ping Insurance Co−12.336∗∗∗−2.86HK Index−7.813∗∗∗−2.86Hong KongInterest rate−1.367−4.360∗∗∗−2.86Exchange rate−2.301−9.361∗∗∗−2.86∗∗∗and ∗∗denote significance at the 1% and 5% levels, respectively; ADF: augmented Dickey-Fuller.The results indicate that most stock return data and exchange rates are stationary at the first level, whereas the interest rate, crude oil price, and gold index are stationary at the first difference. In Table5, the first column lists the variables. The second and third columns present the values of the ADF test with the first differences, whereas the last column displays the critical values at 5%. These values were computed for each country and their respective stock returns. Table 5 demonstrates that the critical values for all countries remain the same at −2.86. The ADF test (first difference) in the US for the crude oil price was −7.369 and for the gold price index was −12.367. Similarly, the value of the ADF test (the first difference between the interest and exchange rates) was −4.558 and −3.664 for Turkey; however, it was −4.360 and −9.361 for Hong Kong. The ADF test (first difference) for the exchange rate for Hong Kong was less than that of Turkey.The ADF test (at level) was also computed for each country and their respective stock returns. The macroeconomic variables of the exchange and interest rates for the US have ADF test (at level) values of about −2.946 and −1.368, respectively. Likewise, these respective values are −0.369 and −1.962 for Turkey and −1.367 and −2.301 for Hong Kong. Thus, this ADF test appropriately demonstrates the proper stationarity of time-series data for these nations.


## 4.3. Regression Results and Computation of Coefficients

To compute the regression results and calculate the coefficients, we used (1) to investigate the influence of macroeconomic variables, including the gold index (Gi), crude oil price (Co), interest rate (Ir), and exchange rate (Ex). Similarly, equation (2) investigates the influence of economic news (S) sentiment on stock returns for all countries. In the first stage, the influence of the gold index, crude oil price, interest rate, and the exchange rate was analyzed on the stock returns of the US stock market without involving the sentiment of the economic news (S). For this purpose, we used the stock returns of the top five performing companies along with the Standard and Poor’s 500 index. Table 6 lists the results for each country.Table 6
Coefficient outputs for the US without sentiment.
ParametersCompaniesγ0γ1γ2γ3γ4SLPApple0.0011−0.1133∗∗ (−2.6342)−0.1980 (−1.2358)−0.1194∗∗∗ (−3.5632)−0.2146∗ (−1.7523)Citi Group0.1487−0.0208∗∗ (−1.9730)−0.0044 (−1.0260)−0.0423∗∗∗ (−4.5320)−0.4389∗∗ (−2.3255)General Electric−0.0025−0.0893∗∗∗ (−3.6981)−0.1387∗ (−1.7283)−0.0713∗∗ (−2.0861)−0.1269∗∗∗ (−7.0036)Microsoft−0.0000−0.1417∗∗∗ (−12.5853)−0.0793 (−0.5581)−0.0931∗∗∗ (−3.2260)−0.0749∗∗ (−1.9931)Google−0.0009−0.1962∗∗∗ (−8.9680)−0.0217∗∗ (−2.0025)−0.1492∗∗∗ (−2.6089)−0.0034∗∗∗ (−2.7763)US Index0.0007−0.0995∗∗∗ (−10.8875)−0.1643∗∗ (−2.6987)−0.0804∗∗∗ (−3.8910)−0.1529∗∗∗ (−3.1250)OLSApple0.0032−0.0251 (−1.2365)−0.2153 (−0.9630)−0.1023∗∗ (−2.6980)−0.0126∗ (−1.6420)Citi Group0.1692−0.3654 (−1.3623)−0.0321 (−0.6980)−0.0214∗∗ (−2.3610)−0.3647 (−1.2045)General Electric−0.0030−0.0896∗∗∗ (−3.1250)−0.0032∗ (−1.6402)−0.0631 (−1.2561)−0.0378∗∗ (−2.1253)Microsoft−0.0003−0.1023∗∗ (−2.0021)−0.0032 (−1.236)−0.3680 (−1.2365)−0.2256 (−0.0023)Google−0.0036−0.1062∗∗ (−2.0125)−0.0361∗∗ (−2.5540)−0.3690∗∗ (−2.3600)−0.3265∗ (−1.6430)US Index0.0362−1.2632 (−6.5243)−0.3620 (−1.3620)−0.5326∗∗ (−2.3687)−0.2569∗∗ (−1.9682)∗∗∗, ∗∗, and ∗ indicate significance at the 1%, 5%, and 10% levels, respectively.Each column in Table6 provides the coefficient value for each macroeconomic variable. Moreover, the rows indicate the top five performing companies’ stock returns. For instance, in the case of the SLP (single-layer perceptron model), the coefficients of macroeconomic variables for Apple Company are 0.0011, −0.1133, −0.1980, −0.1194, and −0.2146. Similarly, Table 6 provides the values of coefficients for other companies also. The findings suggest that the influence of the gold index, oil price, interest rate, and exchange rate is highly significant and negative. As a result, any positive shock in the exchange rate causes stock returns to rise. Similarly, an increase in the gold index causes the stock return to decrease because the gold index is a relatively less risky option for investors. These results align with the existing literature (e.g., [51–54]). Subsequently, we employ equation (2) to investigate the influence of the gold index, crude oil price, interest rate, exchange rate, and sentiment of economic news on stock returns in the US stock market. For comparative analysis, we also report results of estimated coefficients based on OLS (Ordinary least square). All the coefficients are mostly negative and significant. However, the SLP model outperforms the OLS because most of the coefficients are highly significant, unlike the OLS.Table7 presents the results that include sentiment as another variable. Like Table 6, the columns indicate the coefficient values, including the coefficient of sentiment, and the rows indicate the companies. For instance, the first row provides the values of coefficients for Apple (i.e., −0.0003, −0.1164, −0.2797, 0.0737, −0.2751, and −0.0391).Table 7
Coefficient outputs for the US with sentiment.
ParametersCompaniesγ0γ1γ2γ3γ4γ5SLPApple−0.0003−0.1164∗ (−1.6842)−0.2797∗∗ (−2.2201)−0.0737∗∗∗ (−3.6128)−0.2751∗∗ (−2.6681)−0.0391∗∗∗ (−8.6680)Citi Group−0.4559−0.0178∗∗ (−2.0973)−0.0035 (−1.0260)−0.1832∗∗ (−2.5320)−0.1885 (−1.3255)−0.0654∗∗∗ (−3.225)General Electric0.00501−0.0036 (−0.7123)−0.0521∗ (−1.8283)−0.0101∗∗ (−2.0861)−0.0335∗∗∗ (−7.0036)−0.1026∗∗ (−10.5638)Microsoft0.0089−0.0020∗∗∗ (−12.5853)−0.1756 (−0.5581)−0.0646∗∗∗ (−3.2260)−0.2097∗∗ (−1.9931)−0.0068∗∗ (−2.8969)Google0.0029−0.0116∗ (−1.9080)−0.0968 (−1.0025)−0.0019∗∗∗ (−3.6157)−0.09032∗∗ (−2.0563)−0.0769∗∗∗ (−5.8801)US Index−0.0007−0.0550∗ (−1.7675)−0.2368∗ (−1.6987)−0.0142∗∗∗ (−3.8910)−0.2369∗∗ (−2.1250)−0.1199∗∗ (−2.3601)OLSApple−0.0023−0.0012∗∗ (−2.0360)−0.1578∗ (−1.6890)−0.0589∗∗∗ (−3.5580)−0.2875∗∗ (−2.3690)−0.6890∗∗∗ (−6.3281)Citi Group−0.0036−0.3482∗ (−1.6480)−0.1258 (−0.3670)−0.3470∗∗ (−2.3600)−0.1244 (−0.7820)−0.0224∗ (−1.8950)General Electric0.3600−0.0125 (−0.0367)−0.0362∗ (−1.6432)−0.0125∗ (−1.6980)0.7785∗∗∗ (3.6650)−0.4457∗∗∗ (−6.3325)Microsoft0.0025−0.0480∗∗ (−7.6380)−0.7412 (−0.4450)−0.0889∗∗ −(2.2236)−0.2287 (−0.3668)−0.0560 (−1.3580)Google0.0235−0.2258 (−1.4480)−0.0036 (−0.4412)−0.4521 (−1.0231)−0.4425∗∗ (−1.9632)−0.0125∗∗∗ (−3.1425)US Index−0.0034−0.0142 (−1.2365)−0.0147 (−1.5243)−0.1252∗ (−1.7630)−0.1425∗∗ (−2.5630)−0.2250∗∗(−2.1125)∗∗∗, ∗∗, and ∗ indicate significance at the 1%, 5%, and 10% levels, respectively.Likewise, the subsequent rows provide the coefficient values for the remaining companies under US stock returns. The findings suggest that the gold index, interest rate, and exchange rate have highly significant and negative influences. All the coefficients of these variables are negatively significant at the 1% level, and any positive shock in the exchange rate causes the stock returns to increase. The coefficient of social media sentiment toward economic news is highly significant and negative at the 5% and 1% significance levels. The statistical significance of the EUNS indicates that during the period of a fiscal budget announcement, any economic uncertainty news negatively influences stock returns. For comparative analysis, we also report results of estimated coefficients based on OLS (ordinary least square). All the coefficients are mostly negative and significant. However, the SLP model outperforms the OLS because most of the coefficients are highly significant, unlike the OLS.In the second experiment, we assessed the values of coefficients for Turkey with two experimental settings. In the first setting, we used (1) to investigate the influence of the gold index, crude oil price, interest rate, and exchange rate on stock returns in the Turkish stock market without including sentiment as a variable. We used the stock returns of the top five performing firms and the BIST 100 index. Table 8 presents the findings. The columns in Table 8 indicate the coefficients, and the rows indicate the selected firms.Table 8
Coefficients outputs for Turkey without sentiment.
ParametersCompaniesγ0γ1γ2γ3γ4SLPAK Bank−0.7458−0.1942∗ (−1.8251)0.0308 (0.3680)−0.0794∗∗ (−2.6687)−0.0104∗∗∗ (−3.6897)Arcelik0.0015−0.0818 (−1.0021)0.0595∗ (0.2421)−0.0194∗∗∗ (−3.2258)−0.1275∗∗∗ (−6.3360)Dogus−0.0045−0.0053 (−1.2253)−0.0081 (−0.0225)−0.0042∗∗ (−2.021)0.0085∗∗∗ (−5.4420)KOC Holdings0.0003−0.0586 (−1.5581)0.0790 (1.0258)−0.1313∗∗ (−1.9980)−0.0181∗ (−1.8412)Vestel−0.0013−0.0672 (−1.3760)−0.0659 (−0.9985)−0.0202∗∗∗ (−6.2213)−0.1177∗∗∗ (−8.6601)Turkey Index−0.0017−0.0668 (−0.8962)0.1446 (0.0258)−0.1187∗∗ (−2.6621)−0.0128∗∗ (−2.0170)OLSAK Bank−0.2563−0.0124 (−1.6347)0.5692∗∗ (2.3610)0.0365 (1.3481)−1.3650∗∗ (−2.5560)Arcelik0.0012−1.4458 (−1.5520)0.0523 (0.0030)−0.0365∗ (−1.8963)−1.2480∗∗ (−2.4120)Dogus−0.2570−0.0124 (−0.2250)−0.1240 (−0.7890)−0.1022 (−1.3580)−0.3658∗∗∗ (−3.6558)KOC Holdings0.0014−0.0124 (−1.3560)0.0124 (1.3610)−0.1245∗ (−1.8860)−0.0115 (−1.5520)Vestel0.0036−0.0023 (−0.1258)−0.2568 (−0.3480)−0.2540 (−0.4580)−0.1024∗∗ (−2.5580)Turkey Index0.3152−0.0558 (−0.4280)1.4580∗ (1.8320)−0.0530∗ (−1.9680)−0.9630∗∗ (−2.4520)∗∗∗, ∗∗, and ∗ indicate significance at the 1%, 5%, and 10% levels.These firms are AK Bank, Arcelik, Dogus, KOC Holdings, Vestel, and Turkey Index. More explicitly, the values of coefficients for AK Bank are −0.7458, 0.0015, −0.0045, 0.0003, −0.0013, and −0.0017. Similarly, for Arcelik, the values of coefficients are 0.0015, −0.0818, 0.0595, −0.0194, and 0.1275. Subsequently, the remaining rows of Table8 present the values of coefficients for the remaining top five firms in Turkey. According to the results, the coefficients for the interest and exchange rates are extremely significant and negative. Any positive shock in the exchange rate leads to increased stock returns. Similarly, an increase in the interest rate causes stock returns to decrease. However, the crude oil price and gold index are insignificant. These findings are similar to the results reported by Toparlı et al. [55] in the context of Turkey using the time-varying parameter vector autoregressive approach. For comparative analysis, we also report results of estimated coefficients based on OLS (Ordinary least square). All the coefficients are mostly negative and significant. However, the SLP model outperforms the OLS because most of the coefficients are highly significant, unlike the OLS.In the second experimental setting, we used equation (2) to investigate the influence of the gold index, crude oil price, interest rate, exchange rate, and the additional variable of the sentiment of economic news on stock returns for the Turkish stock market. Table 9 displays the results for this experimental setting. The columns in Table 9 indicate the coefficients from γ° to γ5, including the sentiment variable. The rows list the values of the top five firms in Turkey, as given in the previous experimental setting. Our findings suggest that the gold index, interest rate, and exchange rate have highly significant and negative influences. All the coefficients of these variables are negatively significant at the 1% level. An increase in the price of the gold index becomes attractive for investors, which negatively influences stock returns. Any positive shock in the exchange rate causes the stocks’ returns to increase. The coefficient of EUNS is highly significant and negative, indicating that any economic uncertainty news negatively influences stock returns during the period leading up to the fiscal budget release. For comparative analysis, we also report results of estimated coefficients based on OLS (ordinary least square). All the coefficients are mostly negative and significant. However, the SLP model outperforms the OLS because most of the coefficients are highly significant, unlike the OLS.Table 9
Coefficient outputs for Turkey with sentiment.
ParametersCompaniesγ0γ1γ2γ3γ4γ5SLPAK Bank−0.5609−0.0328 (−1.3694)−0.0448 (−0.3325)−0.0016∗∗ (−2.5821)−0.0123∗∗∗ (−5.3368)−0.4417∗∗∗ (−7.3621)Arcelik0.0009−0.0123∗∗ (−2.3324)0.0001 (1.0025)−0.0068∗∗ (−2.3369)−0.0037∗∗∗ (−7.9980)−0.1147∗∗ (−2.0178)Dogus−0.0053−0.0094∗∗∗ (−3.6687)−0.0142 (−0.2258)−0.0020∗∗∗ (−3.1201)−0.0082∗∗∗ (−2.9836)−0.0081∗∗∗ (−3.6612)KOC Holdings−0.0025−0.0186∗∗∗ (−4.6674)−0.0031 (−1.6237)−0.0102∗∗ (−1.9932)−0.0023∗∗∗ (−12.3546)−0.1057∗∗∗ (−8.3691)Vestel0.0034−0.0150∗∗∗ (−12.9986)−0.0027 (−0.0089)−0.0088∗ (−1.6794)−0.0071∗∗∗ (−3.2257)−0.0947∗∗ (−2.6389)Turkey Index−0.0028−0.0393∗∗∗ (−16.2258)0.0066 (1.0028)−0.0226∗∗∗ (−3.2292)−0.0068∗ (−4.5528)−0.1636∗∗∗ (−3.2630)OLSAK Bank−0.5630−0.5230 (−1.4030)−0.4236 (−0.8632)−1.7410∗ (−1.8820)−0.1423∗∗∗ (−3.7430)−0.4620∗∗∗ (−6.9930)Arcelik0.0742−0.4620∗ (−1.9630)−0.1456 (−0.4310)−0.1036∗∗ (−2.2310)−0.4250∗∗∗ (−4.8632)−0.4520∗ (−1.8850)Dogus0.0042−0.0467∗∗ (−2.4520)−0.4460 (−0.3336)−0.0325∗∗ (−1.996)−0.3460 (−1.4630)−0.2200 (−1.3870)KOC Holdings0.3360−0.7630∗∗∗ (−3.6690)−0.3340 (−0.6980)−0.0111 (−1.4520)−0.0021∗∗∗ (−7.6460)−0.0364∗∗∗ (−3.6540)Vestel0.4560−0.7520 (−1.6280)−0.0240 (−0.4420)−0.3360 (−1.3120)−0.1270∗∗ (−2.4630)−0.1860 (−1.4850)Turkey Index−0.1120−0.0125∗∗∗ (−6.2240)0.0460 (0.4430)−0.3640∗∗ (−2.1360)0.0125∗∗ (−2.3120)−0.1240 (1.4560)∗∗∗, ∗∗, and ∗ indicate significance at the 1%, 5%, and 10% levels, respectively.In the last experiment, we estimated the values of coefficients for Hong Kong. This experiment was also divided into two scenarios. In the first, we used (1) to investigate the influence of the gold index, crude oil price, interest rate, and exchange rate on stock returns in the Hong Kong stock market without involving the sentiment variable. To accomplish this, we used the stock returns of the top five performing companies alongside the Hong Kong stock exchange index. Table 10 presents the results of this experimental scenario.Table 10
Coefficient outputs for Hong Kong without sentiment.
ParametersCompaniesγ0γ1γ2γ3γ4SLPChina Merchant Bank−0.2290−0.1439 (−0.2548)−0.0030∗∗ (−2.0145)−0.0259∗∗ (−2.3684)−0.2028∗∗∗ (−3.0125)Industrial and Commercial Bank0.6643−0.4067 (−1.3582)−0.0082∗∗ (−2.8560)−0.0736∗∗ (−1.9984)−0.5098∗∗ (−2.1584)Ping Insurance co−0.6343−0.2024∗ (−1.7837)−0.0023∗∗ (−2.3689)−0.0268∗∗∗ (−3.2514)−0.2131∗∗∗ (−3.5562)HK Index−0.0008−0.1593∗ (−1.8920)−0.1876∗∗ (−2.0258)−0.0792∗ (−2.5218)−0.1759∗∗ (−1.9725)OLSChina Merchant Bank−0.0210−0.2350 (−0.4610)−0.0412 (−1.6310)−0.0145∗ (−1.7820)−0.1048∗∗ (−2.1050)Industrial and Commercial Bank0.4420−0.0230 (−0.2250)0.1205∗ (−1.6630)−0.3660 (−0.8960)0.5520 (1.4420)Ping Insurance Co.−0.3360−0.1020 (−1.0020)−0.1254∗∗ (−1.9980)−0.3360∗∗ (−2.2630)−0.3360∗ (−1.8820)HK Index0.2250−0.2236 (−1.3650)−0.3360∗ (−1.6630)−0.4450∗∗ (−2.2540)−0.4420∗ (−1.6880)∗∗∗, ∗∗, and ∗ indicate significance at the 1%, 5%, and 10% levels, respectively.The columns in Table10 display the values of the coefficients, and the rows indicate the top three companies in Hong Kong: China Merchant Bank, Industrial Commercial Bank, Ping Insurance Co., and HK Index. Table 9 indicates that the coefficient values of the China Merchant Bank are −0.229, −0.1439, −0.0030, −0.0259, and −0.2028. Likewise, the coefficient values of the Industrial and Commercial banks are −0.229, −0.1439, −0.0030, −0.0259, and −0.2028. Likewise, the coefficient values of the Industrial and Commercial banks are −0.6643, −0.4067, −0.0082, −0.0736, and −0.5098. These findings suggest that the crude oil price, interest rate, and exchange rate are highly significant and negatively influenced. All coefficients of these variables are negatively significant at either the 5% or 1% significance levels. Any positive shock in the exchange rate causes the stocks' returns to increase. These results are similar to those of Khan et al. [56], who reported that the oil price negatively influences stock returns in the short and long run. For comparative analysis, we also report results of estimated coefficients based on OLS (ordinary least square). All the coefficients are mostly negative and significant. However, the SLP model outperforms the OLS because most of the coefficients are highly significant, unlike the OLS.In the next scenario, we employ equation (2) to investigate the influence of the gold index, crude oil price, interest rate, and exchange rate by including the sentiment of economic news on stock returns in the Hong Kong stock market. Table 11 provides the results of this scenario for Hong Kong.Table 11
Coefficient outputs for Hong Kong with sentiment.
ParametersCompaniesγ0γ1γ2γ3γ4γ5SLPChina Merchant Bank−0.0184−0.0958∗ (−12.3360)−0.0036 (−0.3368)−0.0193∗∗ (−2.0588)−0.1512∗ (−1.9018)−0.0428∗∗∗ (−5.8862)Industrial and Commercial Bank−0.0259−0.0589∗ (−5.2261)−0.0086 (−0.8962)−0.0197∗∗∗ (−3.2258)−0.1119∗∗ (−2.5581)−0.6913∗∗∗ (−6.3542)Ping Insurance Co0.4591−0.1638∗∗ (−2.5120)−0.0027 (−1.2250)−0.0238∗∗∗ (−2.8960)−0.1813∗∗ (−5.2285)−0.3442∗∗∗ (−4.3325)HK Index0.0062−0.0032∗∗∗ (−7.8891)−0.0239∗ (−1.8251)−0.0501∗∗∗ (−4.5520)−0.0237∗ (−13.2884)−0.1295∗∗∗ (−7.2258)OLSChina Merchant Bank−0.0125−0.0456∗∗∗ (−4.6320)−0.0653 (−0.0021)−0.2350 (−1.3350)−0.1020 (−1.0050)−0.4580∗∗ (−2.4420)Industrial and Commercial Bank−0.8630−0.0030∗ (−1.8060)−0.0032 (−0.0056)−0.1120∗∗ (−2.3660)−0.1130 (−0.3340)−0.4460∗∗∗ (−3.5620)Ping Insurance Co0.5560−0.0040 (−1.2050)0.1120 (0.6670)−0.5520 (−0.0780)−0.1140∗ (−1.6680)−0.0050∗∗ (−2.1220)HK Index0.3360−0.0010∗ (−1.6640)0.4450 (0.6680)−0.4380 (−0.4450)−0.0052∗ (−2.1100)0.5630∗∗ (−2.0050)∗∗∗, ∗∗, and ∗ indicate significance at the 1%, 5%, and 10% levels, respectively.The effects of the gold index, interest rate, and exchange rate are highly significant and negative. All the coefficients of these variables are negatively significant at the 1% level. Any positive shock in the exchange rate increases the stock returns. The coefficient of social media sentiment toward economic news is highly significant and negative. Thus, during the period of a fiscal budget announcement, any economic uncertainty news negatively affects stock returns. For comparative analysis, we also report results of estimated coefficients based on OLS (ordinary least square). All the coefficients are mostly negative and significant. However, the SLP model outperforms the OLS because most of the coefficients are highly significant, unlike the OLS.


## 4.4. Results of Predictions with Macroeconomic Factors and without Sentiment

In this section, we analyze the performance of the proposed model in terms of predicting the returns of different companies in the US, Turkey, and Hong Kong. In the first step, we tested the models using macroeconomic factors without including sentiment. We trained the single-layer perceptron model using macroeconomic variables such as the exchange rate, interest rate, gold index, and oil price across 50 epochs. In regression, these variables are regarded as dependent variables, whereas the target variable is the returns of various companies.The parameters of a single-layer perceptron include the weight optimizer, which is Adam; the loss function is “Mean Squared Error,” and the batch size is 4. The input layer of a single-layer neural network consists of units equal to dependent variables, while the last consists of one unit (neuron) representing the output value. Figure3 depicts the MSE loss during single-layer neural network training for enterprises from all nations. The first graph illustrates the training loss on the data of all Hong Kong companies, whereas the second graph depicts loss curves on US companies, and the third graph depicts curves on Turkish companies. The graphs show that a single-layer neural network converges quite smoothly and with near-zero error.Figure 3
Training loss curves of the companies of different countries including Hong Kong, the United States, and Turkey without sentiments.In addition, we have computed the values of RMSE (root mean square error), MAE (mean absolute error), and MSE (mean squared error) to evaluate the robustness or performance of single-layer perceptrons and the OLS method. Table12 shows the values of RMSE, MSE, and MAE for companies in Hong Kong, the US, and Turkey with single-layer perceptron. Each part of Table 12 shows the results of different companies. These scores are computed by using the actual and predicted values of returns. It is observed from Table 12 that values of RMSE, MSE, and MAE are quite low, which is an indication of best performance.Table 12
Results of single layer perceptron for all companies of Hong Kong, the US, and Turkey without sentiment.
Results of single-layer perceptronRMSEMSEMAEHong KongHK Index0.06700.00450.0450Ping Insurance Co0.06640.00440.0473Industrial and Commercial Bank0.09860.00970.0680China Merchant Bank0.07870.00620.0570United StatesUS Index0.05550.00310.0327Microsoft0.05520.00300.0366Google0.05890.00350.0409General Electric0.06230.00390.0411Citi Group0.22760.05180.1730Apple0.07060.00500.0495TurkeyBIST index0.04150.00170.0041Vestel0.07090.00500.0469KOC Holdings0.07960.00630.0573Dogus0.04990.00250.0211AK Bank0.10130.01030.0746Arcelik0.09620.00930.0684However, AK Bank of Turkey's RMSE score is slightly higher when compared to companies from other countries. In addition, for comparison, we repeated the same experiments using the OLS method as shown in Table13. It is observed from Table 13 that the values of RMSE, MSE, and MAE with the OLS technique are generally the same as with the SLP method. However, for certain companies, the values of error with the OLS approach are higher than with the SLP approach, which demonstrates the feasibility of ANN-based approaches. Furthermore, the SLP is currently based on single-layer, but performance improves when the depth is increased to multi-layers to capture more information from features. The smallest loss values also reflect another realisable value: that predictions become more accurate when macroeconomic factors are considered.Table 13
Results of OLS method for all companies of Hong Kong, US, and Turkey without sentiments.
Results of OLSRMSEMSEMAEHong KongHK Index0.07310.00530.0479Ping Insurance co0.07400.00550.0055Industrial and Commercial Bank0.08180.00670.0589China Merchant Bank0.08140.00660.0592United StatesUS Index0.04560.00210.0304Microsoft0.05190.00270.0375Google0.05820.00340.0407General Electric0.06590.00430.0451Citi Group0.23050.05310.1754Apple0.06890.00480.0477TurkeyBIST Index0.00331.10120.0024Vestel0.06000.00360.0396KOC Holdings0.08150.00660.0594Dogus0.05130.00260.0180AK Bank0.10160.01030.0757Arcelik0.08900.00790.0636


## 4.5. Results of Predictions with Macroeconomic Factors and Sentiment

We evaluated the model's performance in the second stage by including both sentiments and macroeconomic factors. In this experimental setting, the variables of linear regression include the exchange rate, interest rate, gold index, crude oil prices, and sentiment variable. We trained the single-layer perceptron model with these variables for 50 epochs and performed the task of prediction. All of these experiments are repeated with firms from other countries. The training loss curves of different experiments are depicted in Figure4.Figure 4
Training loss curves of the companies of different countries including Hong Kong, Turkey, and the United States with sentiments.The first graph shows the loss curves of Hong Kong companies, the second graph shows the results of Turkey’s companies, and the last graph shows the loss curves of the United Nation's companies. Graphs show that SLP models converge relatively rapidly and loss values reach zero. In addition, the results in the form of RMSE, MSE, and MAE of SLP models with the companies of all countries are also computed as given in Table14. Table 14 contains the findings of companies from various countries. These results are computed by combining actual and predicted return values. Table 14 shows that the values of RMSE, MSE, and MAE are relatively low, indicating excellent performance. As shown in Table 15, we also assessed and extracted the performance of both macroeconomic factors and sentiments using the standard linear regression approach. It has been noticed that the error values with SLP employing sentiments are better than the OLS approach; for example, the MSE value of SLP is 1.10, while the MSE value of OLS is 1.26, which is more than SLP. As a result, it is logically stated that macroeconomic factors and sentiments have a significant effect on returns.Table 14
Results of the SLP method for all companies of Hong Kong, US, and Turkey with sentiments.
Results of single-layer perceptronRMSEMSEMAEHong KongHK Index0.07230.00520.0541Ping Insurance co0.06890.00470.0495Industrial and Commercial Bank0.08730.00760.0653China Merchant Bank0.08590.00740.0633United StatesUS Index0.05460.00300.0333Microsoft0.05670.00320.0380Google0.05470.00300.0394General Electric0.06060.00370.0409Citi Group0.00121.45640.0008Apple0.07670.00590.0524TurkeyBIST Index0.00361.26060.0026Vestel0.06700.00450.0470KOC Holdings0.08070.00650.0631Dogus0.06140.00380.0215AK Bank0.11020.01220.0858Arcelik0.08970.00800.0673Table 15
Results of OLS method for all companies of Hong Kong, US, and Turkey with sentiments.
Results of OLSRMSEMSEMAEHong KongHK Index0.07840.00620.0584Ping Insurance Co0.07730.00600.0541Industrial and Commercial Bank0.08520.00730.0639China Merchant Bank0.07990.00640.0595United StatesUS Index0.04790.00230.0319Microsoft0.05070.00260.0368Google0.05990.00360.0414General Electric0.05970.00360.0415Citi Group0.04290.00180.0022Apple0.07170.00510.0496TurkeyBIST Index0.00341.16080.0025Vestel0.07560.00570.0511KOC Holdings0.08280.00690.0645Dogus0.05200.00270.0228AK Bank0.10720.01150.0844Arcelik0.08650.00750.0673


## 5. Discussion and Comparisons

Stock market forecasting and analyzing stock returns under different factors comprise a developing field in financial research. For corporate organizations, the stock market is an economic driver that mobilizes assets and provides investment opportunities for investors at various levels, such as national, international, and institutional levels, and those who desire to increase their profits without incurring losses. Researchers have employed historical data on stocks in existing research studies to perform stock market analyses or forecasting tasks [17]. However, some research studies have involved the sentiment data for particular events on social media platforms with stock data to more accurately model stock market trends [19–21] because data analytics based on social media plays an important role in countries’ stock market trends. All these analyses have been conducted through diverse approaches, of which ANNs and traditional intelligence-based models are the most prevalent. In recent years, the use of stock forecasting models based on artificial intelligence, particularly deep learning algorithms, has grown. Nevertheless, some regression-based machine learning models have also been employed, such as support vector regression. Nonetheless, finding the most optimal methods is a critical field of study.In the same vein, stock markets reflect a country’s economic health; thus, in order to properly assist investors and other shareholders, the effects of macroeconomic variables on stock market returns should be assessed. During stock investment decisions, the existence and unpredictability of macroeconomic factors guide investors with ideas about whether an investment will earn high or lower returns. Changes in macroeconomic variables can considerably influence stock market pricing, stimulating the interest of economists and investors. Hence, the involvement of macroeconomic variables in analyzing stock market trends benefits investors and policymakers because extensive knowledge permits investors to make more informed and wiser decisions. The influence of the relationship between macroeconomic factors and stock returns must be understood to more accurately model stock market trends and patterns. From this perspective, this study contributes to the existing literature by analyzing the influence on stock returns by considering macroeconomic variables.In previous studies, this influence has been studied and demonstrated through different statistical and traditional regression methods. However, compared to them, this study proposed a more refined and effective approach using single-layer neural networks to carry out regression analyses. In addition, this study included the EUNS as an additional variable to macroeconomic variables to analyze the stock market returns more accurately.Furthermore, we analyzed the stock returns of three well-established countries: the US, Turkey, and Hong Kong. Among these countries, we selected the top four or five biggest companies, for which we computed the values of the regression coefficients. The findings demonstrate that the gold index, interest rate, and exchange rate are extremely significant and negative for all these countries. In similar lines, EUNS is also negative and significant.


## 6. Conclusion

This study investigated the influence of macroeconomic variables (i.e., the gold index, crude oil price, interest rate, and exchange rate) in the context of EUNS on stock market returns. For the empirical process, we used the daily data for all these variables for a specific set of countries: the US, Turkey, and Hong Kong. Later, we employed single-layer neural networks and ordinary least-square regression to calculate the regression coefficients. The results reveal that the gold index, interest rate, and exchange rate are highly significant and negative for all these countries. Moreover, EUNS is also significant and negative in estimating stock returns. We calculated EUNS only for the period of fiscal budget announcements for the US, Turkey, and Hong Kong. As EUNS is negatively significant, it causes panic in stock market participants, which may ultimately lead investors to withdraw their investments. Therefore, regarding the policy implications of this study, it is important to control negative news about the economy that can panic investors during sensitive periods. Similarly, individual investors should have portfolios that include gold and stocks during uncertain periods to avoid abnormal losses. In our future research studies, we intend to expand the dataset on EUN tweets to cover a longer period. Furthermore, data regarding the other macroeconomic variables can also be enhanced.



---

*Source: 4646733-2022-08-27.xml*