Prediction of Economic Growth by Using Machine-Learning Algorithms through Sentiment Index Analysis in Economy of Pakistan

The neural network method's ability to mimic nonlinear communications without prior information is a major benefit for accurate function approximation. It differs from ARIMA and linear regression, which need linearity and may not work for all data sorts. Compared to (seasonal) ARIMA models, neural networks yield similar results. Neural networks also model and predict multivariate time series using causal and co-integration research. In contrast to the traditional economic forecasting approach, machine-learning techniques have prioritized precise forecasting without predetermined assumptions or conclusions. Owing to their enhanced predictive abilities and technological advancements, they provide more adaptability and have gained widespread acceptance in several fields. In terms of estimating US real estate values, machine-learning technology fared better than traditional econometric models, as shown. Total there were 131601 economic and financial news, which may include the phrases along with the names specified by the bank, and it may also include local media and mainstream. Machine learning uses the strength of data-driven algorithms and state-of-the-art computational techniques to improve decision-making in a range of industries. The findings of this research contribute to better forecasting practices and show how machine learning may provide more accurate forecasts in real-world scenarios.


Introduction
For financial analysts, predicting the movement of the stock price index has remained a difficult task.They are intricate because stock market forecasts are influenced by the political, social, and economic conditions with political and social climate of the country.The goal of the current study is to use machine learning to create an efficient model using monthly data from February 2004 to December 2020.An artificial neural network employing backpropagation and long-and short-term memory is used to forecast the movement of the Karachi Stock Exchange (KSE) based on 26 administrative, political, social, and economic indices.The KSE 100 index movement was predicted by the model created in this study with 99 percent accuracy.According to the forecasts, the KSE 100 index would not move from its current level of approximately 40,000 points until September 2023 (Jadoon et al., 2024).The financial development of firms and states is hindered by the stock market's uncertainty and investing in stocks that are anticipated to rise in value will maximize profits for investors who are fully informed of changes in a stock's value.In order to minimize losses and maximize profits, investors look for methods and resources (Ali et al., 2023).
GDP is a state's total economic output during a specific period of time, which includes all goods and services.It makes no difference if they are foreigners or natives.If they are present in the nation, the government counts their production as GDP.Understanding Pakistan's economy, which is expanding rapidly with over 220 million people, requires an understanding of GDP measurement and analysis.For the government and policymakers, GDP forecasting is essential, and precise estimates aid in their planning.GDP forecasting is a tool used by government authorities to address issues like poverty and unemployment as well as other issues that might be resolved with better policies (Maccarrone et al., 2021).It is vital to forecast Pakistan's stock market's actions since doing so could boost investor confidence, reduce macroeconomic volatility, and promote economic expansion (Ghani et al., 2022).
Previous research anticipated economic time sequence using various methods.Box and Jenkins developed the Auto-Regressive Integrated Moving Average univariate forecasting model in 1976.This approach is popular because it can reliably predict occurrences when all its parameters are satisfied.One study by (Bhadwaj, 2020) predicted Irish inflation using the ARIMA model.For accurate inflation forecasting, the study provided a mechanism for computing essential characteristics such degree of incorporation, auto-regressive terms, and affecting average terms.This study shows how ARIMA may predict Irish inflation.Research projects have regularly used the ARIMA model to forecast economic indicator variety.ANNs are used as excellent forecasting models in finances, business, finance, liveliness, and hydrology.They are trusted and often used for forecast.The ANN model was developed to analyze input-output relationships, making it suitable for seasonal time series data.Researchers are interested in utilizing ANNs to predict events in numerous disciplines.Economics, banking, and hydrological studies have shown how successfully this statistical tool can discover complex patterns and produce accurate projections.
Input variables in forecasting models help provide accurate forecasts by gathering latent population features.The performance of the stock market in each nation is determined by a multitude of factors.Empirical research has demonstrated that when technology advances the country's stock market performance is significantly influenced by a number of macroeconomic factors, shareholder interest, and state administrative quality (Adams & Klobodu, 2016).The neural network method's ability to mimic nonlinear connections without prior information is a major benefit for accurate function approximation.It differs from ARIMA and linear regression, which need linearity and may not work for all data kinds.Compared to (seasonal) ARIMA models, neural networks yield similar results.Neural networks also model and predict multivariate time series using causal and co-integration research (Uddin & Tanzim, 2021).Review of literature.To predict Turkish economic development, (Oral, 2019) studied exponential leveling algorithms to find the best method.The study found that the Holt-Winters smoothing exponential model best forecasts Turkey's economic development indexes' seasonal trends.(Dongdong, 2018) found an ARIMA (12, 1, 12) model for Chinese monthly CPI data which may be converted to final analysis.

1.
What is impact of machine learning on economic growth?2.
How to estimate latest results by using machine learning in economy of Pakistan?

Literature Review
An effective means of raising capital for states, businesses, and individuals is the stock market.Because of its high liquidity, interested parties can easily transact in stocks.In every economy, the number of individuals trading on the stock market and the stability of stock market trends are the main factors influencing capital and financial market development (Chhajer et al., 2022).The fluctuations of the stock market serve as an indicator of the state of the economy in a country; a positive performance implies growth in the economy, while a bad performance implies the opposite.An increase in investors looking for profit opportunities is observed in the issuance of Initial Public Offerings (IPOs) to raise funds during optimistic stock market trends.Consequently, greater investment fuels economic expansion and activity (Zaffar & Hussain, 2022).The application of machine learning (ML) and computational intelligence techniques to predict stock market fluctuations has significantly increased (Kumbure et al., 2022).ML is used to examine and find patterns in data.ML methods quickly and accurately provide accurate conclusions from complex data (Rouf et al., 2021).Artificial Neural Networks (ANN) are presently the leading approach in the literature for processing nonlinear pattern data (Rao & Reimherr, 2023).The ANN backpropagation technique is frequently applied for trustworthy prediction of future data (Siregar & Wanto, 2017).The data from the Pakistani stock market is analysed in this study.In order to create the model using the most important macroeconomic, social, political, and administrative quality indicators for Pakistan.
In order to determine which exponential smoothing method would work best for forecasting Turkey's economic growth indicators, (Oral, 2019) analyzed the existing ones.The Holt-Winters smoothing exponential model is the most effective technique for forecasting the seasonal patterns seen in Turkey's commercial growth indicators, according the study's conclusions.An ARIMA (12, 1, 12) model generated accurate projections when (Dongdong, 2010) studied Chinese monthly CPI data, suggesting that it may be used to guide monetary policy choices.Using an ARIMA model, (Kiriakidis & Kargas ,2013) correctly predicted the Greek GDP downturn.Kharimah et al. (2015) used ARIMA (1, 1, 0) to forecast the consumer price index in Bandar Lampung, and the results showed that the CPI would increase in the future.(Dritsaki, 2015) forecast Greece's real GDP using an ARIMA (1, 1, 1) model and saw steady increase.(Yang et al. 2016) projected China's GDP using the ARIMA (2, 2, 2) model.Using ARIMA models, (Wabomba et al. 2016) accurately forecasted Kenya's GDP's annual earnings.Uwimana et al. (2018) utilized ARIMA to project GDP development in African nations until 2030.In order to predict India's real GDP, Agrawal (2018) used ARIMA, and the long-term results were reliable.Finally, Abonazel and Abd-Elftah (2019) determined that the ARIMA model (1,2,1) was suitable for projecting the GDP of Egypt until 2026.Samimi et al. (2005) projected Iran's GDP using artificial neural networks and the exponential smoothing method.They utilized quarterly data from 1998 to 2003 and these methodologies to predict the GDP for 2004 and 2005.The results of their investigation showed that neural networks outperformed other methods in GDP forecasting.In order to forecast the per capita GDP for eight areas in China's Yunnan Province, (Dong & Zhu, 2014) performed a research.To forecast the variable, they used the corrected exponential smoothing approach as well as the exponential smoothing method.The Modified Exponential Smoothing Model (MESM) outperformed the other techniques, according to the data.
In contrast to the traditional economic forecasting approach, machine-learning techniques have prioritized precise forecasting without predetermined assumptions or conclusions.Owing to their enhanced predictive abilities and technological advancements, they provide more adaptability and have gained widespread acceptance in several fields.In terms of estimating US real estate values, machine-learning technology fared better than traditional econometric models, as shown by (Plakandaras et al., 2015).Previous studies on price increase estimates by (Inoue & Kilian, 2008) and (Medeiros et al. 2019) show that these representations have also shown their effectiveness in low-frequency data sets.Due in part to their ability to provide precise forecasts, their use in a growing number of industries-such as traffic and real estate forecasting-has increased.Several machine-learning algorithms that have been evaluated for their ability to forecast credit 88avoidances were presented by Alonso and Carbó (2021).Bhardwaj et al. (2022) employed both conventional and deep learning models to anticipate the yearly GDP per capita of 33 OECD nations.
In the meanwhile, (Srinivasan et al., 2023) discovered that the polynomial regression model outperformed the linear regression model in their prediction of the Indian GDP using sophisticated machine learning techniques.These findings highlight how crucial it is to use cutting-edge machine learning algorithms when predicting the economy.In conclusion, these results provide insightful information on how well machine-learning algorithms forecast the GDP of India.There are three primary versions of the hybrid ANN-ARIMA model in the literature.When analyzing time series data, the ARIMA model compares expected and actual data while accounting for mistakes.In order to include a non-linear component, Zhang (2003) proposes using an ARIMA-ANN model that consists of an ANN and an additively considered, integrated Moving Average (MA).Three distinct datasets are used to test this model: Wolf sunspot data, the Canadian lynx statistics, and the exchange rate data amongst the US dollar and the British pound.Within the ANN framework, these datasets are analyzed and assessed using a variety of simulations and approaches.

Methodology
A branch of study that aims to discern subjective information such as emotion, opinion, and attitude indicated in the text by using tools and techniques from domains such as natural language processing (NLP), statistics, and computer science.Sentiment analysis is a subfield of research.Methods that are used in the process of sentiment analysis (Lexical Approach, Machine Learning Models)

Data Analysis
Total there were 131601 economic and financial news which may include the phrases along with the names specified by the bank and it may also include local media and mainstream: A dataset that is ready to be used and whose sentiment orientation is known already.The Central Bank personnel, academics, alumni, and students of TED University were the individuals that reviewed the news bundles that were formed randomly after they were generated.Question: After reading this news, what are your expectations for the future economic activity?There are 1357 news items that have been labeled ("-1," "0," and "1") 4.1 Models of Machine Learning and Sentiment Indexes (three labels; -1,0,1) respectively The above table tells about the algorithm We report on accuracy tests conducted on scattered-data fitting techniques that are available as ACM algorithms.Three modified Shepard methods and seven triangulation-based approaches-two of which are novel algorithmscomprise the algorithms.Our aim is twofold: first, to assist prospective users in choosing a suitable algorithm; second, to offer a test suite for evaluating the precision of novel approaches (or those that already exist but are not covered in this study).Ten test functions and five sets of nodes, ranging in number from 25 to 100, make up our test suite.Many fields of science encounter the scattered-data fitting problem, where the data usually reflect computed or measured values of some physical quantity-an underlying function that we aim to approximate.The fitting function provides values at locations where measurements are impractical or prohibitively expensive to gather, approximates derivatives or integrals of the underlying function, or provides a surface or contour plot-a graphic depiction of the data.In certain applications, the challenge is to choose the parameters that go into a model of the underlying function (typically using a least-squares fit), and in other applications, the challenge is to smooth away noise in the data values.

Models of Machine Learning and Sentiment Indexes (2 labels;-1,1)
The purpose of this part is to use sentiment analysis to enhance the yearly NEWS estimates issued by the different sources, taking into account the need for precise forecasts given the pandemic period and routine analysis in many Pakistan.In terms of forecast accuracy, the forecasting model that employed signals based on the Fourier transform as inputs in support vector machines and artificial neural networks outperformed all other models: For this reason, choosing an algorithm shouldn't be based only on the survey's results, which are mostly focused on testing accuracy.Additionally, a strategy that is the most accurate for one set of data may not work well for another set of data.On the other hand, all of the techniques used here are general-purpose and faithfully replicate smooth underlying test functions with suitably dense node sets.The precision with which test functions may be reproduced, the computing expenses incurred during preprocessing and assessment, the amount of storage needed, the flexibility with which restrictions can be handled, and the appearance of the interpolator surface are all factors that go into determining how effective a scattered-data interpolation method is.Apart from these standards, a software programme can also be evaluated based on its robustness, portability, ease of use, modifiability, and flexibility with regard to extra features like data set pre-and postprocessing.

Multi-Layered Perceptron
A basic and well-liked artificial neural system model in machine learning and design recognition is the Multilayer Perceptron (MLP).It is also known as synthetic neurons or perceptions, and it is composed of several layers of linked nodes.Each neuron in an MLP receives input from the coating above it and produces a production using a nonlinear activation function.An input layer, one or more unseen layers, and an output coating make up a typical system.Via a technique known as back-propagation, MLPs may identify intricate patterns and associations in data by modifying the masses and biases of the connections between neurons.Equation ( 4) provides an MLP model's generic form.

Model hybrid
The hybrid model is a cutting-edge tactic that leverages the best features of both techniques to enhance time series forecasting.It combines ARIMA, ANN.ARIMA captures the linear relationships, and auto-regressive nature of the data, but ANN is better at handling complex nonlinear interactions and capturing subtle patterns.In this hybrid model, the ANN is supplied with the residuals amongst the predicted and actual principles after the ARIMA model is used to make initial predictions.By identifying and simulating the nonlinear relationships present in the residuals, the ANN considerably enhances the predictions.By fusing the benefits of ARIMA and ANN, the hybrid model aims to improve time series forecasting's accuracy and robustness.The hybrid model is a novel strategy that improves time series forecasting by utilising the best aspects of both approaches.It blends ANN and ARIMA.While ANN is superior at handling intricate nonlinear interactions and identifying subtle patterns, ARIMA is better at capturing the linear correlations and auto-regressive character of the data.In this hybrid model, initial predictions are made using the ARIMA model, and then the ANN is given the residuals between the predicted and actual principles.The ANN significantly improves the predictions by recognising and modelling the nonlinear relationships found in the residuals.The hybrid model seeks to increase the accuracy and resilience of time series forecasting by combining the advantages of ANN and ARIMA.

Conclusion and Policy Recommendations
Through comparison analysis, the MLP inside the Artificial Neural Network (ANN) architecture was developed to be the best model.The best-fitted model was determined by evaluating the mean absolute error and root means square error among the several forms that were examined.The results demonstrate that machine-learning methods outperform traditional forecasting methods.Machine learning algorithms outperformed conventional techniques, as seen by the more accurate predictions they generated.This outcome emphasizes how important and beneficial it is to use machine learning in predicting.Machine learning uses the strength of datadriven algorithms and state-of-the-art computational techniques to improve decision-making in a