2Plag Major-Updated report.pdf
2Plag Major-Updated report.pdf
55 Pages 2.5MB
May 19, 2023 10:41 AM GMT+5:30 May 19, 2023 10:42 AM GMT+5:30
Summary
Abstract:
A significant, highly widespread, and drop that tends to take a longer period of time in
15
economic activity timeframe is described as a recession. From the peak of the previous
expansion to the trough of the downturn, economists in general calculate the length that
comprises of a recession. Recessions may only last a few months, but it may take years for the
economy to bounce back and reach its previous peak.
In this paper, we investigate various datasets and its pros and cons and try to give the shot to
speculate the chances of recession, based on Machine Learning techniques and backed by
concrete datasets for better approximation of result. Within a Machine Learning framework,
we try to put in the values, specifically the Chicago Federation National Activity Index
(CFNAI) and its 2 components: Monthly Average of 3 and CFNAI Diffusion Index from a
period of March, 1967 to June, 2022, along with the S&P-500 index and various parameters
associated with it (like 10yr Tbond, % Tbond, 2 year spread fedrate, CPI etc) from the day of
130
the recorded period. Using unscaled, scaled and tuned models of machine learning technique,
the model was able to predict the chances, ranging from 87% to slightly more than 94%. Both
the models are different from each other, and are compiled together for comparison and the
purpose of having a surety about the model being correct in these regards.
I. Introduction:
Recession is defined as a period of economic downturn wherein the economy starts to contract
and it mostly gets evident in the country’s growth as the country’s GDP plunges and the stock
market feels the reverberations and starts to go down, more commonly termed as “bear
31
market”. A series of local or international market shocks can trigger a global financial crisis,
31
which can then turn into a worldwide economic crisis because of the interconnection of the
financial markets. In other cases, a single economic power that is quite huge and a member of
the "big-enough" economies to generate turmoil in other countries could be the source of an
31
economic crisis. This was the case, for instance, with the subprime crisis or what is commonly
called as the Great Recession of 2008, which began in the US and spread to other European
nations and inevitably worldwide as a problem of sovereign debt. The studies argue that firms'
risk management and financing policies had a significant impact on the degree to which firms
were impacted by the financial crisis [1] (Brunnermeier, 2009). Exploration of the 2008 crisis
by Erkens et all [2] hypothesise that this is due to (a) firms with more independent boards raised
more equity financing during the crisis, which caused existing shareholders' wealth to be
transferred to debtholders, and (b) firms with higher institutional ownership took on more risk
before the crisis, which resulted in greater investor losses during the economic crisis. In a
recession, more volatile investments like equities and high-yield bonds typically lose value
while more reliable investments like gold and U.S. Treasuries typically rise. Shares of big
corporations with reliable cash flows and dividends often fare better in downturns on the stock
market.
1
When an economy tends to become lethargic or in case of a straightaway period of plunge, it
becomes almost a necessity to watch on the spending and take undue risks that could harm an
27
individual’s finances. When a recession begins, many businesses may turn to layoffs in order
to reduce costs as they try to manage falling demand for the products offered and/or the
services they tend to provide. Also, the effects of the recession on unemployment tends to
become visible long after the recession period begins, which is evident from the various
10
recession that the world has seen earlier. To quote the reports that the National Bureau of
Economic Research, or more commonly NBER, published, during the 2008 Economic
Recession (that started showing its effect from December of 2007 and came to an end around
June of 2009), the U.S. unemployment rate was just 5% in April 2008 (five months into that
period), a slight rise from 4.7% six months earlier. But surprisingly, seven months after the
stock market's bottom and four months after the recession's official end, in October 2009, the
unemployment rate rose to a mammoth 10%. This is due to the fact that the corporate world
is very fast in cutting down their costs for a product, but in general maintain more caution
when they had to add back the cost by hiring a new employee even when the company starts
to bounce back towards recovery.
With more potential regressors than there are observations, the usage of ML models is now
proven to be able to manage massive volumes of data and provide high assurances in terms of
accuracy of the final model. Chen et al. considered the healthcare as one of the sector affected
by the Great Recession of 2008 [4] and thus, examined the paper based on the health care
2
expenditures along the health care spending distribution, based on the Medical Expenditure
Panel Survey (MEPS) dataset from 2005-06 and 2007-08. To determine the various
42
relationships between the recession and health care spending along the health care expenditure
distribution, quantile multivariate regressions are used.
On the other hand, machine learning (ML) is a crucial method for creating models that can
automatically correlate all the data from various economic sources and respond to various
57
issues. In 2022, many economic analysts debated whether the economy was in recession or not,
given some economic indicators pointed to recession, but others did not.
Although machine learning algorithms have long been employed in categorization issues, they
are now increasingly being used in the social sciences, notably in the field of financial sectors
19
(Dabrowski, 2016) [5]. The hidden Markov model, switching linear dynamic system, and Naive
Bayes switching linear dynamic system models were all implemented in this work. The hidden
55
Markov Model stated that: First, the assumption of a limited horizon states that the probability
of being in a state at a given time depends only on that state (t-1) and second, the assumption
of a stationary process states that, given the current state, the conditional (probability)
distribution over the next state remains constant.. Nyman and Ormerod used the ML’s Random
Forest technique for the dataset between 1970(Q2)-1990(Q1), and from 1990-2007 which
118
comprised of GDP growth period [6]. This model was able to predict the result of about six
quarters ahead and the results were stronger in case of the economy of the UK compared to the
US. In another paper [7] both of them extended their analysis by looking at how each of the
explanatory variables affected the Great Recession of the late 2000s. They were able to further
the investigation by breaking down business and non-financial household debt into separate
categories and discovered that the Great Recession was significantly influenced by both
household and non-financial company debt though, their explanatory models exhibit
significant non-linearity.
Using the 3 months to 2 year period, the Treasury term spread was used as a benchmark by Liu
and Moench [8] and they paid particular attention to the subject of whether or not the leading
indicators surveyed before in the literatures go beyond the Treasury term spread to provide
insight into potential future recessions. The Italian economy was employed as the database,
and machine learning guided tools were used as the analysis method, in the paper [9] presented
by Paruchuri, who investigated the idea of machine learning in economic forecasting. By
examining the financial characteristics that can be used as a recession indicator, Estrella and
Mishkin [10] conducted additional analysis of the US recession, wherein they were making
conclusions from the result they got (about one to eight quarters ahead) and Stock prices,
currency exchange rates, interest rates, and monetary aggregates were assessed separately as
well as in relation to other financial and non-financial indicators. Siakoulis, Petropoulos,
Stavroulakis and Vlachogiannakis used statistical ML models (Random Forest, Support vector
Machine, Neural Network and Extreme Gradient Boosting) [11] on daily stock, bonds and daily
3
market from 39 countries as a method to predict stock market crisis. Papadimitriou, Matthaiou
and Chrysanthidou examined the economic recession using the yield curve generated by the
ML techniques using the treasury bils and bonds from 1976 to 2014 [12] , which would be able
to forecast the future value thereby helping in yield curve formation, a negative curve indicating
the period of recession. Zahedi and Rounaghi [13] were instrumental in creating an Artificial
Neural network for the generation of predicted stock prices, with the dataset recorded from
their native Tehran Stock Exchange and used 20 accounting variables for creating a big dataset
that could help their model. They were able to determine (based on the outcomes of their
120
statistical analyses) that the artificial neural networks (ANN) model is superior to that of its
rivals by using non-linear time series models of analysis. Using real-valued data, principal
component analysis may also effectively predict stock values on their native Tehran Stock
Exchange and pinpoint the major factors that influence stock prices.
Vadlamudi in his paper [14] discussed the implications of Machine Learning techniques on
economic predictions: A real-time study to look into the influence of ML in FCP is suggested
because the study showed a leading strategy for achieving financial growth and adaptability in
corporate organisations. He also played a key contribution in identifying the crucial function
that some methods play in the forecast of insolvency and creditworthiness, roles that other ways
had not adequately addressed.
Camska and Klecka made their research based on prediction models that are being used for
prediction and expansion and centred it on predictive models for financial trouble in
corporations [15]. The goal for them became an examination of economic cycles and how
different phases arising out of them affect the prediction scores. The prediction models can be
used to quickly and affordably assess a corporate financial status, which will help to reduce
business risk. The accounting data used in the research was taken from Albertina, a prepaid
22
corporate database. Manufacturing of metal items, manufacturing of machinery, and
construction businesses are divided into sound and insolvent firms. In this study, 18 models
were chosen and then used to describe expansion and contraction in company data. The primary
22
descriptive statistics, such as mean, median, and trimmed mean, along with the absolute
difference contrasting expansion and recession, serve to characterize the final scores attained.
Samitas, Kampouris, & Kenourgios, using their investigation of contagion risk, and structured
financial network, were able to develop an EWS (Early Warning System) based on network
analysis ML tools [16] to predict some upcoming crisis in the economic world. They expanded
11
upon the literature that suggests a connection between network connections in the global
financial industry (channels of stock indexes, nationwide debt-security bonds) and potential
contagion risk during crisis situations. To develop dynamic financial networks, they
11
specifically compute dynamic conditional correlations between all pairings of stocks, indexes,
sovereign bonds, and CDS. The networks that have been retrieved are then analysed to identify
11
any potential for contagion during times of crisis. Then, they presented a machine learning
strategy to anticipate and forecast the potential for contagion risk within financial networks.
We can see how correlations have changed over time and are organised by areas. As we can
4
see, a sudden rise in correlations in the case of stock indexes is connected to financial crisis
over time. The most significant support for this statistic comes from the nearly same behaviour
11
of all geographical correlations, particularly in the case of the Eurozone, Asia/Pacific, and
11
American markets, irrespective of the fact that even if stock exchange markets operate at
various times and in various ups and downs. Other research paper that were presented and used
different strategy to predict the economic recession were done by Memon et al. as they
presented their way to predict using Covid-19 as the background [17] of their research, and using
ARMA and TGARCH data from 1989-2020 as their model of research to extract out the data
that can be used at probit model.
The first corundum of the paper was using which dataset and variable to use for predicting the
recession since there is no fool-proof data that supports the accurate prediction. According to
a 2018 study by Loungani and others [18], the majority of recessions between 1992 and 2014 in
63 nations were missed by economists in both the public and private sectors. The first thought
of using the dataset was the quarterly GDP growth rate of major economies around the world,
but it was quickly rejected since there weren’t too many available data (eg- after the
disintegration of USSR, the quarterly data for Russia is available only after 1993, while the
Chinese maintained the data only after 1990). Yearly data wasn’t favourable either due to it
being too little (maintained and in the open domain only from the 1960s onwards, with major
data from countries like France available only after 1970s), so there wasn’t any continuity. The
reason why the search for the dataset was diluted to only the US economy is due to the fact that
being the largest economy of the world, with major trade governed through the US Dollar,
whenever it faces any economic stress, the world faces the aftershock.
One of the major indicators about any recession that has been triggered by the US was the
Chicago Federation National Activity Index or CFNAI in abbreviation. This index uses a
weighted average of more than eighty actual economic activity parameters for the preceding
10
period. A single, summary measurement of a common element in the entire national economic
statistics is offered by the CFNAI. As a result, changes in the CFNAI throughout time closely
mirror times of economic expansion and contraction.
10
The CFNAI Diffusion Index represents the difference between the total absolute value of the
weights for the underlying indicators whose contribution to the CFNAI is positive in a given
10
month and the total absolute value of the weights for those indicators whose contribution is
negative or neutral in that same month over a three-month period. The CFNAI Diffusion Index,
whenever below the threshold of -0.35, have indicated that the economy is under recession.
Fisher et all in their paper outlined the failure of other policies and other Federation banks to
capture the accurate representation of recession and thereon, gave some statistical model that
5
was the determinant of the current Index and also calculated the magnitude to which it could
go [19].
The other dataset that was used for the paper was the S&P-500 data. The Standards & Poors-
500 (hereon S&P-500) is an index very similar to the Nifty-100 or the Nifty-50 back in India,
which has been used since ages to measure the stock performances of 500 major corporations
25
that are listed on American stock exchanges, from NYSE to NASDAQ. It is one of the most
commonly followed equity indices. As of December 31, 2020, more than $5.4 trillion was
invested in assets linked to the index's performance, with the index reaching its highest point
on 2 January, 2022.
One of the key reason to pick it was the historical evidence and the volume of the data that it
presents, from December 1927 to current, updated daily (as and when the market trades). The
paramaters associated with S&P-500, along with the high and low price and trading volume
includes 10yr Tbond, % Change Tbond ,2yr SpreadFedrate ,% Change Fedrate, Nonfarm
Payrolls , % Change Payrolls , CPI and % Change CPI Date.
Since the features we needed for our dataset were not conveniently included in a downloadable
dataset, we had to download each feature separately and combine them together 77
into one
dataframe. We were able to pull each economic feature separately from FRED (Federal
Reserve Economic Data from the Federal Reserve Bank of St. Louis) using Quandl, which also
had the added bonus of automatically calculating selected transformations if we chose to do so,
and the financial feature was downloadable from Yahoo! Finance so we downloaded the dataset
and created the transformed variables in Excel and imported the dataset as a CSV.
6
3.2 About Quandl:
Quandl is a website that is used by professionals in the field of economics and financial
services, with the aim to get the data pertaining to economy, stocks, finances and other
alternative datasets that could be used for studies, report and/or for making business studies
and data analysis. Those who are willing to use it can use the free datasets, buy out the
datasets, upload some data and even sell some datasets in order to make money. Quandl
enables corporations to benefit from information from data. They gather, enhance, place to
use, and supply distinct, top-notch, and useful non-market data to institutional clients.
We created Recession labels from a list of start and end dates. We finally concatenated each
feature and the labels using an inner join to create one data-frame. After creating a correlation
heatmap, we selected the features we wanted to include in our final dataset (each of the features
fall under a certain category; employment, monetary policy, inflation, bond market, or stock
market). Finally we saved this dataset as a CSV and performed some descriptive statistics on
the data.
7
Fig 2. Ratio Scale of S&P 500 Bull and Bear Market (Credits: Yardeni)
The US Treasury also provides a way for the users around the world to access the data regarding
the Treasury rates and the bond period.
63
The United States Department of the Treasury is the executive department of the federal
government responsible for developing and executing the nation's economic and financial
policies. The Treasury Department7 was established by the First Congress of the United States
on September 2, 1789, and is led by the Secretary of the Treasury, who is a member of the
President's Cabinet.
⮚ Managing the nation's finances, including collecting taxes, paying bills, and managing
the national debt.
⮚ Issuing U.S. currency and coins.
⮚ Enforcing financial
86
laws and regulations.
⮚ Overseeing the U.S. Mint and the Bureau of Engraving and Printing.
⮚ 7Administering the Internal Revenue Service (IRS).
⮚ Providing economic and financial advice to the President and Congress.
110
The Treasury Department is a critical part of the federal government
78
and plays a vital role in
the nation's economy. The department's work helps to ensure the stability of the financial
system, the soundness of the nation's currency, and the fairness of the tax system.
8
145 67
⮚ Managing the national debt: The Treasury Department is responsible for managing the
national debt, which is the total amount of money that the federal government owes to
its creditors. The Treasury Department issues Treasury securities, which are bonds,
117
notes, and bills that are sold to investors to raise money to pay for the government's
expenses.
⮚ Issuing U.S. currency: The Treasury Department bears the responsibility for issuing the
currency in US. They print and mint coins and bills, and it also distributes them to banks
and other financial institutions. 7
⮚ Enforcing financial laws and regulations: The Treasury Department is responsible for
enacting upon the financial laws and regulations, which are designed to protect
consumers and investors. The Treasury Department investigates and prosecutes
financial crimes,
73
such as fraud and money laundering.
⮚ Overseeing the U.S. Mint and the Bureau of Engraving and Printing: The Treasury
79
Department oversees the U.S. Mint and the Bureau of Engraving and Printing, which
are the two agencies
139
that are responsible for producing U.S. currency and coins.
⮚ Administering the Internal Revenue Service (IRS): The Treasury Department
administers the Internal Revenue Service (IRS), which is the agency that collects taxes
7
in the United States. The Treasury Department sets tax policy, and it also provides
7
guidance to taxpayers on how to file their taxes.
⮚ Providing economic and financial advice to the US President and to the Congress: The
7
Treasury Department provides economic and financial advice to the President and
Congress. The Treasury Department analyzes economic data and trends, and it also
makes recommendations on economic policy.
9
Fig: The US Treasury data, important for the Yield Curve (Source: US Treasury Website)
It has now been an inherent nature for data to contain scales of values that oscillate in between
the variables.
Some machine learning techniques, such as normalisation, which scales all variables to values
between 0 and 1, perform significantly better when all variables are scaled within the same
range. This has an influence on algorithms like support vector machines and k-nearest
neighbours as well as methods like linear models and neural networks that use a weighted sum
of the input.
This is true for output variables, also known as target variables, such as numerical values
expected when modelling regression predictive modelling
30
problems.
It is frequently useful to scale or convert both the input and target variables in regression
situations.
It is simple to scale input variables. You can use the scale objects manually in scikit-learn, or
the more handy Pipeline, which allows you to chain a series of data transform objects together
before utilising your model.
10
3.4 Scaling of Target Variables
There are two methods for scaling target variables.
The first option is to handle the transform manually, while the second is to use a new automatic
method.
Create the object that tends to be used for transform e.g. a MinMaxScaler.
Then, Fit this transform function on the training dataset.
Apply the transform function to the subdivided dataset consisting of training and testing
datasets.
Invert the transform for any forecast that was made.
The “TransformedTargetRegressor”
30
tends to prepare the transform of the targeted variable with
the help of the same training data used to fit the model. On applying that inverse transform on
any new data provided when calling the predict() function, it returns those predictions in the
correct scale.
Each ellipse border represents the location of the loss function's constant value (the innermost
ones are
2
identified), and the red X represents the location of the optimal values of A[0] 2
and
A[1]. By convention, the loss function's constant values are evenly spaced, therefore contour
lines that are closer together suggest a "steeper" slope. In this plot, the centre at the X is quite
shallow, whereas the distance away is quite steep. Furthermore, one of the ellipses' diagonal
axes is steeper than the other.
● Rescaling Options
This wasn't covered before, but there are essentially just two options for rescaling features.
Consider the case where the first variable runs from -1 to 1, and the second one has a range
between 99 to 101: both the aforementioned features have (about) the same standard deviation,
11
but the second variable has a much bigger mean.
2
Consider the following scenario: first variable
is still between -1 and 1, while second one is between -100 and 100. They have the same mean
this time, but x2 has a significantly greater standard deviation. Gradient descent and similar
algorithms can become2 slower and less trustworthy in each of these circumstances. As a result,
we want to make sure that all features have the same mean and standard deviation.
3.5 Methodology:
119
Fig: Illustration of the Methodology for the Linear and Logistic Regression Model
This happens to be the general methodology that explains well how132the Logistic Regression
model works. Firstly, a dataset is fed into the model, which divides it into two sub-categories:
training and testing data. The golden ratio for dividing training and testing data is 70:30, or
80:20. After the model is trained and has learnt how to make predictions, from the framework
that was set for it, we test it for testing dataset and check out the accuracy by comparing it to
the results of the training dataset.
It can help you avoid overfitting the model to the training data.
It can give you a more accurate estimate of the model's performance.
It can help you identify any biases in the model.
It can help you tune the hyperparameters of the model.
12
Fig: Methodology for the Classification Models using the S&P-500 dataset
19
We seek to compare the model accuracy of Support Vector Machine, K-Nearest Neighbour,
Decision-tree classifier models and find out which model is the most reliable and which one
has the best fit with regards to our dataset. Our data-set is a complication of pre-existing
Standards & Poor-500 Index (S&P-500) and important economical indicators which are
imported via FRED’s database with the help of the Quandl command. FRED’s data-base helps
us expand our pedagogy and help us work with complex economical indicators such as 10 Year
T-bond, 2yr spread, % change in fed-rate, change in cpi and much more.
All of the indicators are taken in as features which are visualised and correlated via a heat map.
Furthermore, we generate a “Project Dataset” which houses recession labels. A “0” label
indicates no recession while a “1” label indicates a recession.
One thing that helped us to a great extent was the fact that more than 50 years of data was
available as archives, which helped us visualise19a trend and maximise the effort of predicting
an economic recession. We seek to compare Support Vector Machine, Decision Tree, K-
Nearest Neighbour classifier to see the differences in their classification reports and to check
which one will have the best accuracy of them all. Since we are dealing with financial and
economics entailing datasets we are wary of subsiding changes and differences in the models
entailing to the change in world economics. However our primary focus with the methodology
is to understand the best fit for our procured and concatenated data-set and to idealise the best
possible model by visualising and computing the accuracy and the respective
classification reports.
13
Fig: Methodology for plotting a Yield Curve using the US Treasury datasets
We intend to plot and project a yield curve that can serve as a significant signal for forecasting
an economic recession utilising complicated analogies in machine learning, as shown in our
second figure in this research. This procedure entails acquiring a data collection that is easily
accessible online. The "US Treasury Index" is the set of data in question. The dataset comprises
treasury index values from 1970 to 2022 and is highly coherent.
Through proper cleaning and wrangling of this data and by applying suitable Machine learning
we can avoid disturbances and unimportant artifacts. This further leads us to idealising and
procuring a trend which can be studied and examined to come close to the possibility of
predicting an economic recession. It is to be noted that financial data sets are vulnerable and
always prone to change due to the current economic fluctuations and a change in modern
economic and finance indicators and this serves as an inspiration to come close to a goal of
brainstorming and visualizing a proper technique to avoid a devastating incident like a global;
recession and wide-scale job loss.
Below we describe the methodology for plotting a yield curve using US Treasury data:
● Gather the necessary data. You can find US Treasury data on the US Treasury
Department's website.
14
● Select the bonds you want to use to construct the yield curve. You can choose bonds with
different maturities, such as 1 Y, 2 Y, 5, 10, and 30 year bonds.
45
● Calculate the yield to maturity for each bond. The yield to maturity can de explained as
33
the revert back amount you will earn if you hold the bond to maturity and receive all of
the scheduled interest payments.
144 92
● Plot the yield to maturity for each bond on a graph. The x-axis should represent the
maturity of the bond, and the y-axis should represent the yield to maturity.
72
● Connect the points on the graph to create a yield curve. The yield curve will show the
relationship between the yield to maturity and the maturity of the bond.
33
Here are some additional tips for plotting a yield curve:
⮚ Use bonds with similar credit ratings. This will help to ensure that the yield curve is not
distorted by differences in credit risk.
⮚ Use bonds that are actively traded. This will help to ensure that the yield curve is
accurate and up-to-date. 45
⮚ Use a variety of maturities when constructing the yield curve. This will help to provide
a more complete picture of the current state of the yield curve.
94
⮚ Humped yield curve: A humped yield curve is one where the yield to maturity is lowest
in the middle maturities and then increases as the maturity of the bond increases. This
87
is a sign that investors are expecting interest rates to rise in the future.
146
The shape of the yield curve can be used to predict future economic conditions. For example,
48
a normal yield curve is often seen as a sign of economic growth, while an inverted yield curve
is often seen as a sign of economic recession.
The models that were used in the making of this project, namely
● Linear Regression
114
● Logistic Regression
● Decision Tree Classifier
● K-nearest Neighbour (KNN)
● Support Vector Classification
The reason for picking up all these models was the fact that there is no one-size-fits-all answer
3
to the question that we framed for ourselves. The best model for predicting economic recessions
will depend on the specific data set that is being used.
35
In general, SVM models are a good choice for predicting economic recessions when the data
35
is accurate and the data set is not too large. KNN models are a good choice for predicting
35
economic recessions when the data is noisy or the data set is large. Decision tree models are a
good choice for predicting economic recessions when the data is complex and the data set is
not too large.
15
49
3.6 Linear Regression:
49
A linear method that corresponds to the proximity of the relationship between a scalar response
and one or more interpretive variables is linear regression (the responses mentioned above are
95
also known as dependent and independent variables). In contrast to multivariate linear
regression, which predicts numerous correlated variables dependent on each other, instead of
8
just a single scalar variable, this phrase is more specific.
In linear regression, linear predictive functions are used to model associations, with the
parameters that remain unknown in the model being estimated from the data. Such type of
models are called linear models. The conditional mean of the response is typically considered
to be a related function of the values of the explanatory variables (or predictors); the conditional
median or some another quantile is usually placed.
20
The model parameters are quite easy to be understood due to the linear shape. Additionally,
linear model theories (which are mathematically easy and fair) are widely known. Furthermore,
a lot of contemporary modelling tools are built on the foundation of linear regression [20]. If we
20
take an example, linear regression more often than not provides a good round-off to the
underlying regression function, especially when the sample size is tiny or the signal is very
faint.
36
The first regression analysis method for which the researchers undertook an in-depth research
and saw plenty of its use in actual applications was linear regression. This is because models
with linear dependence on their uncertain parameters are in a simple way fits the linear models
82
than their non-linear counterparts. Plus, it is simpler to determine the statistical attributes and
characters of the resulting estimators.
c=intercept; and
16
Fig 3. Line of best fit and linear regression (Credits: upgrad)
111
The line of best fit is based on changing m's and c's values. The differences that arise between
26
the observed and predicted values are known to be the predictor error. The values of m(slope)
26
and c (intercept) are chosen so as to provide the least amount of predictor error. It's crucial to
remember that an outlier can affect a simple linear regression model. As a result, it shouldn't
be applied to large data sets.
2
One major application of linear regression is to analyse and comprehend a data set rather than
simply predict outcomes. Following a regression, one can learn from the learnt weights how
much each characteristic influences the result. For example, if we have two features A and B
that are used to predict cancer rates, and the learned weight for A is significantly greater than
the learned weight for B, this indicates that the occurrence of A is more correlated with cancer
than the occurrence of B, which is interesting in and of itself. Unfortunately, feature scaling
undermines this: because we rescaled the training data, the weight for A (a′1) no longer
corresponds to A values in the real world.
In general, comparing
1
predictors' (unstandardized) regression coefficients to determine their
relative relevance is not a good idea because:
● The regression coefficients for numerical predictors will be determined by the units of
measurement of each predictor. It makes no sense, for example, to equate the influence
of years of age to centimetres of height, or the effect of 1 mg/dl of blood glucose to 1
mmHg of blood pressure.
● The regression coefficients for categorical predictors will be determined by how the
categories were defined. For example, the coefficient of the variable smoking will be
determined by how many categories you construct for this variable and how you handle
ex-smokers.
17
Rather, the relative relevance of each predictor in the model can be assessed as follows:
The standardised version of model variables is substituted to derive the standardised regression
coefficients.
53
1
A variable that has a mean of 0 and a standard deviation of 1 is said to be standardised. Remove
the mean and divide by the standard deviation for each value of the variable.
The unit of measurement for each predictor changes to its standard deviation when the
predictors in a regression model are standardised.
1
We think that by using the same unit to
measure each variable in the model, their values will become comparable.
1
1. the sample distribution of this variable
2. the sample size taken for standardization (smaller the sample size, greater is
the chance of it being more noisy and unstable)
18
4. the design required for the study
In logistic regression, you can evaluate the reduction in deviance that happens as each predictor
is included in the model.
● Regardless of the units of measurement for any variable, R2 and the deviation are
independent.
● This approach offers an impartial evaluation of importance and does not call for specific
domain expertise.
1
Limitations of using the model’s accuracy to assess variable importance:
1. The correlation between predictors will have a significant impact on the improvement
in R2 (or decrease in deviance) (i.e. collinearity). The last predictor included to the
model has a reduced impact on the model's accuracy the higher the correlation between
two predictors. Therefore, we must assume the absence of collinearity for this strategy
to be effective.
2. It is not recommended to compare variable relevance across studies using the model's
accuracy metrics.
1
3.Comparing the change in a predictor necessary to replicate the effect of another one on the
outcome Y
The key idea here is that we are comparing the effect of all predictors in terms of the effect of
a single predictor that we chose to consider as reference.
19
3.7 Logistic Regression
37
A statistical model called the logistic model, also referred to as the logit model, is a simple
regression model that works by guessing and pointing to the event’s likelihood by converting
85
the event's logarithms of the odds into a linear combination of one or more independent
21
variables. Logistic regression, commonly referred to as logit regression, calculates a logistic
model's parameters in regression analysis (the coefficients in the linear combination).
According to its formal definition, binary logistic regression has a single binary dependent
variable (two classes, coded by an indicator variable) with the values "0" and "1," whereas the
independent variables can either be continuous variables or binary variables (two classes, coded
by an indicator variable) (any real value). [22] [23]
37
Only when a selection threshold is included does logistic regression become a classification
12
approach. The classification problem itself determines the threshold value, which is a crucial
component of logistic regression. The precision and recall levels have a significant impact on
the choice of the threshold value. In an ideal situation, precision and recall should both equal
1, but this is very rarely the case.
b) High Precision/Low Recall: In this case, there is a decision that is needed to be made
28
by us: to have a large value of precision or a low value of recall in applications where
we wish to cut down on false positives and at the same time, maintaining the false
negatives.
5
The main distinction that is drawn between logistic regression and its linear counterpart is that
the range of logistic regression is contained within a value between 0 and 1. In contrast to linear
43
regression, logistic regression does not require nor does it demand a linear relationship between
the input and output variables. This is because the odds ratio were converted to a non-linear
84
log transformation. The mathematical function can be defined as:
20
1
Logistic function f(x):
1+𝑒 −𝑥
42
Logistic regression is a statistical model that can be used to predict the probability of a binary
38
event, such as whether someone will pass an exam or not. The model works by estimating the
odds ratio of the event occurring, which is the ratio of the probability of the event occurring to
the probability
138
of the event not occurring. The odds ratio can be increased or decreased by
changing 97the values of the independent variables, which are the factors that are thought to
influence the probability of the event occurring. The logistic function is used to convert the
odds ratio to a probability, and it has a "simple" shape that is easy to interpret.
It makes the least assumptions about the data being modelled since it minimises additional
information, maximises entropy, and maximises entropy.
For many machine learning algorithms, feature scaling through standardisation (or Z-score
normalisation) can be a crucial pre-processing step. For instance, imagine you have a bunch
of data points, each with a bunch of features. Some of the features might be on a different
scale than others. For example, one feature might be the height of a person in meters, while
another feature might be the weight of a person in kilograms.
This can make it difficult for machine learning algorithms to learn from the data. That's
because different features can have different ranges of values. For example, the height of a
person can range from 0 to 2 meters, while the weight of a person can range from 0 to 200
kilograms.
21
13
Feature scaling is a process of transforming the features so that they have a common scale.
This makes it easier for machine learning algorithms to learn from the data.
Normalization and standardization are both effective ways to do feature scaling. However,
normalization is usually preferred because it is more robust to outliers.Here is an example of
how feature scaling can be used. Suppose we have a dataset of people with the following
features:Height (in meters) and Weight (in kilograms).
64
We can normalize the features by subtracting the mean from each 90
feature and then dividing
by the standard deviation. This will give us a new set of features with a mean of 0 and a
standard deviation of 1.
Economic forecasting has always been a difficult problem for economists and policymakers.
Accurately predicting future trends and developments is challenging due to the unpredictable
nature and complexity of economic systems. However, there is a chance to increase economic
forecasting accuracy as machine learning becomes increasingly widespread. The use of
decision tree classifier models for predicting economic recessions is one such application.
122
A sort of machine learning technique called a decision tree classifier model employs a
decision tree to predict a result. It operates by recursively dividing the dataset into smaller
subsets according to the features' values. Based on a selected splitting criterion, such as the
34
Gini index or entropy, the algorithm chooses the most optimal feature to split the data at each
106
stage. The end result is a structure that resembles a tree, with each node denoting a judgement
call based on a feature value and each leaf node denoting a forecasted impact.
To explain the Decision Tree Classifier in simple way: Imagine you have a game where you
have to guess what kind of fruit is in front of you. You could ask questions like "Is it round or
oblong?" or "Is it yellow or green?”. By asking these questions, you can narrow down the
possibilities until you can make a good guess about the type of fruit.
A decision tree classifier is kind of like that game. It's a way for a computer to make a guess
about something by asking a series of questions. In this case, the computer is trying to
classify data into different categories based on a set of features.
22
29 54
For example, let's say we have a dataset of animals, and we want to classify them as either a
cat or a dog based on their features like size, fur color, and tail length. The decision tree
classifier would ask questions like "Is the animal's size smaller than X?" or "Is the fur color
black or white?"
Based on the answers to these questions, the decision tree will follow a different path until it
reaches a conclusion about whether the animal is a cat or a dog. Just like in the fruit game,
the decision tree will keep narrowing down the possibilities until it makes a good guess.
71
Fig: Example illustrating the working of a Decision Tree Diagram
14
The complete population or sample is represented by the root node, which is then partitioned
into two or more homogenous sets.
The process of splitting involves dividing a node into two or more sub-nodes.
A sub-node is referred to as a decision node when it divides into more sub-nodes.
The most important characteristic of Decision Tree Classifier is its power to transform complex
decision-making issues into simplified procedures, resulting in a solution that is easier and
simpler to perceive.
4
A tree can be "trained" by breaking the source set up into subgroups depending on an attribute
value test. The process of repeating this procedure on each derived subset is referred to as
recursive partitioning. The recursion terminates when the split no longer improves the
predictions or when all members of a subset at a node have the same value for the target
variable. Because it doesn't need parameter setting or specialisation, decision tree classifier
development is perfect for exploratory knowledge
4
discovery. Decision trees can be used to
manage high-dimensional data. Decision trees' classifiers are frequently accurate. Decision tree
induction is a common inductive technique for learning classification information.To answer
how the Decision tree Classifier can be used in terms of prediction of the economy, consider it
as this way: Economic forecasting is speculating on how the economy will develop in the
23
future, including how the GDP, inflation, and unemployment rates will change. By training the
model on past economic data and employing it to estimate future trends, decision tree classifier
models may be utilised for economic forecasting.
Periods of economic downturn known as recessions are characterised by a sharp reduction in
economic activity, including GDP, employment, and spending among consumers. A recession
may be anticipated through economic forecasting, which enables decision-makers to take
proactive steps to lessen its effects.
142
By training the model on historical data for important economic variables, such as GDP growth,
employment levels, and inflation rates, decision tree classifier models may be used to forecast
recessions. Next, predictions based on fresh data may be made using the model, and their
precision can be assessed.
A decision129
tree classifier model for economic forecasting is trained using historical data for
important economic indicators, such as Gross Domestic Product growth, inflation rates, and
employment levels. Following that, predictions based on fresh
69
data are made using the model.
By contrasting projected values for the same indicators with actual values, the model's accuracy
is assessed.
40
The benefits of using decision trees are:
There are some limitations attached with the Decision tree Classifier as well. They are
discussed below:
24
3
● Overfitting: When a model learns the training data too well and is unable17
to
generalize to new data, it is called overfitting. This can happen when the model is too
complex or when the training data is not representative of the real world. In decision
tree classifiers, overfitting can happen when
103
the tree is allowed to grow too deep. A
deep tree will have many branches,
17
which can lead to the model learning the training
data too well. This can cause the model to make poor predictions on new data.
30
There are a few ways to prevent overfitting in decision tree classifiers. One way is to
limit the depth of the tree. Another way41
is to use a technique called cross-validation.
Cross-validation involves dividing the training data into two sets: a training set and a
validation set. The143
model is trained on the training set and then
121
evaluated on the
validation set. This process is repeated
18
several times, and the model that performs best
on the validation18set is chosen. Another way to prevent overfitting is to use a
technique called regularization. Regularization adds a penalty to the model's 18
cost
function that discourages the model from learning too complex of a model. This can
help to prevent the model from overfitting the training data.
Pruning is also a method that could act as a possible option to deal with instability. A
decision tree's branches are removed during pruning. This can assist to simplify the
tree and lessen its sensitivity to subtle changes in the environment. The act of pruning
can be done in both ways, manually or automatically.
● Bias: When the model cannot determine the real link between the characteristics and
the target variable, bias in decision trees develops. Bias can lead to poor model
performance. A biased model will make inaccurate predictions on new data. There
are several causes for this, including:
25
⮚ The training set of the model is being overfitted.
● Limited Predictive Power: Decision tree classifier algorithms might not fully
account for the interconnected relationships between economic variables, which
would reduce their accuracy. Several variables, such as the following, can contribute
to limited 3predictive power:
⮚ When a model learns training data too thoroughly and is unable to
125
generalise to new
100
data, this is known as overfitting.
⮚ When a model is very sensitive to even little changes in the training data, it
has a high variance.
⮚ Low signal-to-noise ratio: This happens when the training data do not
adequately reflect the target variable.
69
Using regularization, cross-fitting and limiting the depth of the tree, the predictive
power of the decision tree classifier can be improved.
The process of formulating policies must include accurate economic forecasts. Understanding
the current situation of the economy aids those making decisions in formulating future
economic policies. The use of support vector machine (SVM) models for recession prediction
is one example of how machine learning techniques have improved the accuracy of economic
forecasts.
21
A typical supervised learning approach 34
for classification and regression analysis is the support
vector machine (SVM) model. Finding the hyperplane that optimally divides data points into
distinct groups is how SVM 34models function. The hyperplane is selected so that it51has the
biggest margin, or the largest gap between the nearest data points of various classes. Finding
the support vectors—the data points that are most closely related to the hyperplane—is how
SVC operates. After that, the hyperplane is built to pass as closely as feasible by the support
vectors. The decision boundary, or the line dividing the two classes, is established by the
support vectors, which are crucial.
26
Fig: Support Vector Classification and Hyperplane explanation (Source: Javatpoint)
Consider having a collection of images of cats and dogs. You want to create a device that can
analyse a brand-new image and determine whether it resembles a cat or a dog. To do this, we
tend to use support vector classification (SVC). It operates by identifying a line that divides the
cats from the dogs in the images. The hyperplane is the name of the line that does the distinction
work for us in this case.
SVC examines the images to identify the spots that are most near the line in order to determine
107
the hyperplane. The support vectors are these points. After that, the hyperplane is built to pass
as closely as feasible by the support vectors.
The Support Vector Classification can be divided into 2 groups: Linear and non-linear SVC.
Linear SVC101
are consisting of “linearly separable data” i.e. those that consists of data
32
points
that could be divided into two separate groups using a single straight line. However, a dataset
is considered to be non-linear if it cannot be classified using a straight line, in which case a
non-linear Support Vector Machine classifier is used.
The other important term to understand the Support Vector Classification is Hyperplane.
There might be multiple decision boundaries or planes or lines that are used to segregate the
classes in n-dimensional space, but the most appropriate and the best line should be used for
the purpose of classification of the data points. The boundary that is thus selected is termed as
the hyperplane of the Support Vector Machine.
27
46
They are purely dependent on the features present in the dataset. For instance, the hyperplane
46
will be a straight line if its in a 2D feature space. Additionally, if there are three features, the
hyperplane will tends towards having only two dimensions.
44
3.9 K-Nearest Neighbour:
One of the simplest ML algorithms, based on the supervised learning method, is K-Nearest
3
Neighbour or the K-NN. The basic idea behind KNN is to find the k most similar instances in
24
the training set to a new instance, and then predict the label of the new instance based on the
labels of the k nearest neighbors.
One of the major features of the K Nearest Neighbour is that it can be used for both purpose
74
of Classification as well as for regression. However, in most of the cases, it is used as a
classification.
28
training dataset rather than learning from it immediately. Instead, it uses the dataset to
execute an action when classifying data. During the training phase, the K-Nearest Neighbour
simply saves the information during the training phase, and when it receives new data, it
categorises it into a category that is quite similar to the new data.
To help understand it, consider a simple example. Imagine you have a bunch of pictures of
54
cats and dogs. You want to build a machine that can look at a new picture and tell you if it's a
cat or a dog.
3
K-nearest neighbors (KNN) is a way to do this. It works by finding the 3 most similar
pictures in the training set to the new picture. The pictures that are most similar are called the
"nearest neighbors". The machine then predicts that the new picture is the same as the
majority of the nearest neighbors.
To find the nearest neighbors, KNN looks at the pictures and finds the pictures that are
closest to the new picture. Closeness is measured based on the features of the pictures. For
example, if the pictures are of cats and dogs, then the features could be the size of the ears,
the length of the tail, and the color of the fur.
Once the nearest neighbors are found, the machine predicts that the new picture is the same
as the majority of the nearest neighbors. For example, if 2 of the nearest neighbors are cats
and 1 of the nearest neighbors is a dog, then the machine will predict that the new picture is a
cat.
3
KNN is a powerful algorithm that can be used to solve a variety of classification problems.
3
However, it can be computationally expensive to train, especially for large datasets.
Additionally, KNN can be sensitive to noise in the data.
29
The K Nearest Neighbour works by firstly selecting the value of K. Then, for those K
neighbours (say, if k =4), it calculates the Euclidean distance for those K neighbours and
sorts out the nearest neighbours. The next work done by KNN is to count the data point each
of those neighbours are representing. Then, for the neighbours whose data points are in a
majority, the same data point will be assigned to the value for which we intended to find out
39
the value. The ideal value for "K" cannot be determined in a specific way using a
methodology, thus we must experiment with several numbers to discover the one that works
5
best and fits well for our model. K is best represented by the number 5. A relatively small
number of K, such K=1 or K=2, might be noisy and cause outlier effects in the model.
Although K should have large values, there may be some issues.
17
Overall, KNN is a powerful and versatile algorithm that can be used for a variety of tasks.
135
However, it is important to be aware of its limitations before using it.
A categorical variable, such as whether or not an economic recession will occur, may be
predicted using classification models. A classification model may be trained on past
104
economic data in the context of economic forecasting to determine if the economy will
experience a recession in the future.
One benefit of classification models is that they may give an uncomplicated yes-or-no
response, making them simple to understand and convey to stakeholders and makers. As they
concentrate on classifying data points into distinct groups, they might also be more resistant
to outliers and noise in the data.
30
To forecast a continuous variable, like the severity of a recession, regression models are
utilised. A regression model may be trained on past economic data to anticipate the severity
of a recession in the future in the context of economic forecasting.
Regression models have the benefit of enabling more detailed insights into the elements that
cause recessions. Additionally, they may be better able to capture intricate interactions
134
between many factors, such as the effect of changing interest rates on economic expansion.
However, the individual problem and available data determine how well these types of
models function. A classification model could be more suited, for instance, if the objective is
to forecast if a recession will develop. A regression model would be more suited if the
objective is to comprehend the causes of a recession and forecast its severity.
For predicting economic recessions using machine learning, both classification and
regression models offer advantages and disadvantages. The appropriate model must be
chosen based on the facts and the particular challenge at hand. Regression models may be
better at explaining the causes of a recession and forecasting its severity than classification
models in general for determining whether a recession will occur. We may learn more about
these models' efficacy and determine which model is best for a specific situation by
comparing how well they work.
68
3.11 Time Series Forecasting
Time series forecasting is the process of analyzing historical data to predict future values. It is
a powerful tool that can be used to make informed decisions about the future. However, it is
important to remember that time series forecasting is not an exact science. The predictions
may not always be accurate, and the forecast probabilities may vary greatly. This is because
time series data is often affected by external factors that are difficult to predict.
Despite the challenges, time series forecasting is a valuable tool that can be used to improve
decision-making. The more complete the data, the more accurate the predictions are likely to
be. It is also important to remember that prediction and forecasting are not the same thing.
Prediction is about making a specific statement about the future, while forecasting is about
providing a range of possible outcomes
There are many different methods of time series analysis. Some common methods include:
58
⮚ Trend analysis: This involves identifying the long-term direction of a time series.
For example, a time series might be trending upwards, downwards, or sideways.
⮚ Seasonal analysis: This involves identifying the short-term patterns in a time series.
For example, a time series might have a seasonal pattern of increasing in the
summer and decreasing in the winter.
31
⮚ Cycle analysis: This involves identifying the long-term cycles in a time series. For
example, a time series might have a cycle of increasing for a few years, then
decreasing for a few years, and then repeating.
⮚ Residual analysis: This involves identifying the random fluctuations in a time
series. For example, a time series might have a trend, a seasonal pattern, and a
cycle, but there might also be some random fluctuations.
Time series
66
analysis can be a powerful tool for understanding and predicting the future.
However, it is important to note that no method of time series analysis is perfect. There will
always be some uncertainty in the predictions.
141
Here is an70example of how time series analysis can be used. Suppose you are interested in
predicting the number of70people who will visit your website next month. You could use time
series analysis to analyze the number of people who have visited your website in the past few
months. You could look for patterns in the data, such as a seasonal pattern or a trend. You
could also use statistical models to predict the number of people who will visit your website
next month.
By using time series analysis, you can gain a better understanding of the past behavior of your
website and make more informed predictions about the future
81
⮚ ARIMA: This is a statistical model that can be used to model trends and seasonality in
time series data.
89
⮚ Exponential smoothing: This is a simple method for forecasting that uses weighted
averages of past data.
24
⮚ Neural networks: This is a machine learning method that can be used to model complex
140
relationships in time series data.
32
58
⮚ The data may be influenced by external factors that are difficult to predict.
124
3.12 Yield Curve
A yield
88
curve is a tool used in finance and economics to predict recessions. It is a graph that
shows the relationship between 56
the yields of bonds with different maturity period. The yield
curve can be used to determine the market's expectations for115
future economic growth, inflation,
and interest rates. The yield curve has been found to be a reliable predictor of economic
recessions.
61
By examining the yield curve's form and slope, recessions can be predicted. Long-term
interest rates are greater than short-term interest rates when the yield curve is upward-sloping.
This implies that investors are prepared to put money into longer-term bonds since the market
60
anticipates further economic growth. The long-term interest rates are lower than short-term
interest rates when the yield curve is downward sloping. This indicates that investors are
looking for stable investments in short-term bonds since the market expects a slowdown in
the economy.
47
The link between the interest rates of bonds with various maturities is depicted
53
on a graph
called the yield curve. Investors are ready to pay more for longer-term bonds when the yield
curve is upward sloping, which shows that they are optimistic about the113direction of the
economy. Investors are ready to pay more for shorter-term bonds when the yield curve is
downward sloping, which indicates that they are concerned about the state of the economy.
50
A downward-sloping yield curve is often seen as a sign of an impending recession because 123
it
suggests that investors are expecting interest rates to fall in the future. This can happen when
33
the economy is slowing down and the Federal Reserve is cutting interest rates in an attempt to
stimulate economic growth.
102
An inverted yield curve has been a reliable predictor112of recessions in the past. However, it is
important to note that it is not a perfect predictor and should be used in conjunction with
other economic indicators.
Because it symbolises what the market believes will happen in terms of inflation and
96
economic growth in the future, the yield curve is an effective recession predictor. The yield
56
curve's slope indicates the market's predictions for the future movement of interest rates.
When the yield curve slopes higher, investors anticipate that as the economy expands, interest
137 33
rates will go up. When the yield curve slopes downward, investors anticipate lower interest
rates in the future as the economy weakens.
62
Because it is a good indication of investor mood, the yield curve is also a good indicator of
recessions. During economic downturns, investors frequently avoid risk and favour short-
term, secure assets. In contrast, investors are more ready to take risks and buy long-term
126
bonds during economic expansions. Recessions can be predicted using the yield curve since it
reflects changes in market attitude and expectations.
105 62
Limitations of Using the Yield Curve to Predict Recessions: The yield curve has historically
been a good indicator of economic recessions, although it is not perfect. The yield curve has
certain drawbacks, including the potential for inaccurate recessional signs. The yield curve
may invert sometimes without triggering a recession. This may occur if other elements, such
131
as a sharp reduction in oil prices, contribute to the rise in short-term interest rates.
The variable lead time between an inverted yield curve and a recession is another setback for
anyone willing to draw the conclusions using the yield curve alone. The wait time might
range in length from six months in certain circumstances to eighteen months in others. It may
be difficult for policymakers to act quickly enough to avert a recession as a result of this
variability.
34
Fig: Yield curve and its subcategories (Source: Britannica)
IV. Results:
From the ML strategies deployed, we were able to create a Confusion Matrix for the sake of
accuracy. Also the value were displayed in percentage.
35
Fig: Confusion Matrix for Unscaled Logistic regression
36
Fig: Confusion Matrix for Scaled Logistic Regression
127
For Decision Tree Classifier
The results pertaining to the Decision Tree Classifier are shown below:
76
Fig: Confusion matrix for Unscaled Decision Tree Classifier
37
Fig: ROC Curve for Unscaled Decision Tree Classifier
59
Fig: Confusion Matrix for Tuned Decision Tree with unscaled accuracy.
38
59
Fig: ROC Curve for Tuned Decision Tree with unscaled accuracy.
52
Fig: Confusion Matrix for Tuned Decision Tree with scaled accuracy.
39
59
Fig: ROC Curve for Tuned Decision Tree with scaled accuracy.
147
For Support Vector Classification (SVC)
The results pertaining to the Decision Tree Classifier are shown below:
52
Fig: Unscaled Support Vector Classification accuracy.
40
80
Fig: Confusion Matrix for unscaled Support Vector Classification
41
52
Fig: Confusion Matrix for Support Vector Classification with scaled accuracy
Fig: ROC Curve for Support Vector Classification with scaled accuracy
42
75
Fig: Unscaled KNN Classifier Accuracy
75
Fig: Confusion Matrix for unscaled KNN Classifier
43
Fig: Confusion Matrix for KNN Classifier with scaled accuracy.
The accuracy varied from 87% to a little more than 94% as evidenced from the result. The 1 in
the chart displayed the chances of recession, while a 0 indicated little to no chance of a
recession.
44
Fig: Comparison of the Classification Models
Also used were the CFNAI diffusion index for the values till June 2022, after which some
discrepancies were noticed from the subsequent releases of the CFNAI datasets.
Fig: CFNAI Diffusion Index plotted using ML technique. Notice the trough coincides with the period of economic recession.
45
Fig: CFNAI MA_3 plotted using ML technique.
From Fig 10 and 11, we can see the accuracy of the plotted versus the actual CFNAI Diffusion
Index, which (if it differs) has only minute differences between them. The monthly average of
3 plot was similarly plotted using the ML technique using the dataset.
Fig: A 3-D Yield Curve derived from the Treasury Data, along with the values each axes of the 3D Graph represents.
46
V. Conclusion
The period of recessions have always been the hardest for every sphere of life. There are job
losses and salary cuts, plus the chances to get some new job become slim. The economy gets
mired into a downward curve which impacts everything: inflation, bear market, jobs, revenue
cut, GDP forecast cut etc, and the people suffers from the psychological thing like depression,
anxiety and fear.
Using our dataset obtained from Chicago fed and other source (notably Yahoo! Finance) from
the internet, we were able to clearly show the results from the data provided. The accuracy
varied from the unscaled to the scaled model, showing the results from 87% (for the unscaled)
to 94.44 % (for the scaled regression).
The forecast can help the government in making some haste but confident decisions that could
be done to avert the effects of the financial distress on economy and even delay the recession.
It can also help the market in understanding the dynamics of the world economy since what
affects one will eventually affect the whole world. Things like war, big crisis on a particular
sector will underline what can be the economy’s balance and how it can tilt from negative to
positive. These external factors are always unwanted and can undermine the accuracy of the
model, but not to a big extent since these are reflected on both the market and the other
economic index. It can be also helpful for students and investors for learning from the trends
and the mistakes that could be avoided that could lead to the financial catastrophe.
We are already in the future however in today's dynamic and interconnected global economy,
accurately predicting economic recessions has become a crucial task for policymakers,
investors, and businesses. Traditional economic forecasting models often struggle to capture
108
the complex and non-linear nature of economic systems. However, with the advent of artificial
intelligence (AI) and machine learning (ML), new possibilities have emerged for improving
the accuracy of economic recession forecasting. We believe that there is an endless future scope
and a variety of possibilities which can be realised through even more research lets conclude
on how AI and ML techniques are revolutionizing economic forecasting and enabling more
effective recession prediction.
Predicting economic recessions is a challenging task due to various factors such as the
complexity of economic systems, the influence of external events, and the inherent
uncertainties involved. Traditional forecasting models rely on historical data and assumptions
136
about economic relationships, which can be limited in their ability to capture the dynamic
nature of the economy. AI and ML offer solutions to these challenges by leveraging the power
of algorithms and advanced data analysis techniques.
47
One of the key advantages of AI and ML in economic recession forecasting is their ability to
98
process and analyze large volumes of data. Traditional models often rely on a limited number
of economic indicators, which may not capture the full complexity of the economy. In contrast,
17
AI and ML algorithms can incorporate a wide range of data sources, including financial market
data, social media sentiment, consumer behavior, and macroeconomic variables. By integrating
diverse data sets, these techniques provide a more comprehensive understanding of the
economic landscape.
Traditional economic models often assume linear relationships between economic variables.
However, the real world is characterized by complex interactions and non-linear dynamics. AI
and ML techniques excel at capturing and modeling such relationships, allowing for more
accurate recession forecasting. Through advanced algorithms like deep learning, these
techniques can uncover hidden patterns and detect subtle signals that may be indicative of an
impending economic downturn. By embracing non-linearity, AI and ML offer a more nuanced
understanding of the economy's behavior.
While AI and ML techniques offer powerful tools for economic recession forecasting, human
expertise remains invaluable in interpreting the results. It is crucial to combine the insights
generated by machine intelligence with the knowledge and experience of economists and
48
domain experts. By blending the strengths of AI with human judgment, analysts can make more
informed decisions and gain a deeper understanding of the underlying economic mechanisms
driving recessions.
Additionally, it is essential to address potential biases and ensure that AI-driven models do not
exacerbate inequalities or amplify existing economic disparities. Ethical guidelines and
133
regulatory frameworks should be developed to govern the use of AI and ML in economic
forecasting.
49
VI. References:
[1] M. Brunnermeier (2009) Deciphering the liquidity and credit crunch 2007-08. J. Econ.
Perspect
[2] Erkens, D. H., Hung, M., & Matos, P. (2012). Corporate governance in the 2007–2008
[4] Chen, J., Vargas-Bustamante, A., Mortensen, K., & Thomas, S. B. (2013b). Using Quantile
Regression to Examine Health Care Expenditures during the Great Recession. Health
[5]Dabrowski, J. J., Beyers, C., & de Villiers, J. P. (2016). Systemic banking crisis early
warning systems using dynamic Bayesian networks. Expert Systems With Applications, 62,
225–242. https://doi.org/10.1016/j.eswa.2016.06.024
[6] Nyman, R., & Ormerod, P. (2017). Predicting economic recessions using machine learning
[7] Nyman, R., & Ormerod, P. (2020). Understanding the Great Recession Using Machine
[8] Liu, W., & Moench, E. (2016). What predicts US recessions? International Journal of
[10] Estrella and F. S. Mishkin, "Predicting U.S. recessions: financial variables as leading
indicators", The Review of Economics and Statistics, vol. 80, no. 1, pp. 45-61, 1998.
[11] Chatzis, S. P., Siakoulis, V., Petropoulos, A., Stavroulakis, E., & Vlachogiannakis, N.
(2018). Forecasting stock market crisis events using deep and statistical machine
https://doi.org/10.1016/j.eswa.2018.06.032
[12] Gogas, P., Papadimitriou, T., Matthaiou, M., & Chrysanthidou, E. (2014). Yield Curve
[13] Zahedi, J., & Rounaghi, M. M. (2015). Application of artificial neural network models
and principal component analysis method in predicting stock prices on Tehran Stock
https://doi.org/10.1016/j.physa.2015.06.033
[14] Vadlamudi, S. (2020). The Impacts of Machine Learning in Financial Crisis Prediction.
51
[15] Camska, D., & Klecka, J. (2020). Comparison of Prediction Models Applied in Economic
Recession and Expansion. Journal of Risk and Financial Management, 13(3), 52.
https://doi.org/10.3390/jrfm13030052
[16] Samitas, A., Kampouris, E., & Kenourgios, D. (2020). Machine learning as an early
[17] Memon, A. A., & Oad Rajput, S. K. (2020). COVID-19 Led Economic Recession
https://doi.org/10.2139/ssrn.3656618
[18] An, P., Jalles, J. T., & Loungani, M. (2018). How Well Do Economists Forecast
[19] Fisher JD, Liu CT, Zhou R. When can we forecast inflation?. Economic Perspectives-
[20] Su, X., Yan, X., & Tsai, C. L. (2012). Linear regression. Wiley Interdisciplinary Reviews:
[21] Koç, M., & Barkana, A. (2014). Application of Linear Regression Classification to low-
https://doi.org/10.1016/j.neucom.2013.10.009
52
[22] LaValley, M. P. (2008). Logistic Regression. Circulation, 117(18), 2395–2399.
https://doi.org/10.1161/circulationaha.106.682658
[23] Menard, S. (2002). Applied logistic regression analysis (No. 106). Sage.
53
PERT Chart
Risk Assessment
● The aforementioned dataset associated with the CFNAI (being a Federal Bank in the
US) is subject to change by the authorities in the future predictions. (as it happened
when the data was altered from July, 2022)
116
● Even though the S&P-500 forms the crux of our data set, it is continuously changing
every day and shifts the ethos of forecasting of an economy to the fluctuations in
stock prices.
54
Roles and Responsibilities
55
Similarity Report ID: oid:16158:35734948
TOP SOURCES
The sources with the highest number of matches within the submission. Overlapping sources will not be
displayed.
quantifyinghealth.com
1 2%
Internet
donaldpinckney.com
2 1%
Internet
Sources overview
Similarity Report ID: oid:16158:35734948
chicagofed.org
10 <1%
Internet
easychair.org
12 <1%
Internet
researchgate.net
19 <1%
Internet
Sources overview
Similarity Report ID: oid:16158:35734948
google.com
25 <1%
Internet
Intercollege on 2022-09-21
26 <1%
Submitted works
origin.geeksforgeeks.org
28 <1%
Internet
knowledgehut.com
29 <1%
Internet
Matignon. "Model Nodes", Data Mining Using SAS® Enterprise Miner™, ...
30 <1%
Crossref
Sources overview
Similarity Report ID: oid:16158:35734948
ebin.pub
33 <1%
Internet
files.eric.ed.gov
38 <1%
Internet
medium.com
41 <1%
Internet
science.gov
42 <1%
Internet
upgrad.com
43 <1%
Internet
onlineresource.ucsy.edu.mm
44 <1%
Internet
Sources overview
Similarity Report ID: oid:16158:35734948
Sources overview
Similarity Report ID: oid:16158:35734948
compasiana.com
57 <1%
Internet
vdoc.pub
61 <1%
Internet
fdic.gov
62 <1%
Internet
ballotpedia.org
67 <1%
Internet
medicine.ai.uky.edu
68 <1%
Internet
Sources overview
Similarity Report ID: oid:16158:35734948
numismaster.com
73 <1%
Internet
research.stlouisfed.org
77 <1%
Internet
web.actuaries.ie
78 <1%
Internet
Sources overview
Similarity Report ID: oid:16158:35734948
Vikas Khare, Cheshta Khare, Savita Nema, Prashant Baredar. "Data ana...
85 <1%
Crossref
coinsblog.ws
86 <1%
Internet
ukessays.com
87 <1%
Internet
dokumen.pub
92 <1%
Internet
Sources overview
Similarity Report ID: oid:16158:35734948
core.ac.uk
97 <1%
Internet
pinpdf.com
98 <1%
Internet
preprints.org
99 <1%
Internet
Sources overview
Similarity Report ID: oid:16158:35734948
coursehero.com
113 <1%
Internet
ijimai.org
114 <1%
Internet
Sources overview
Similarity Report ID: oid:16158:35734948
IFoA
119 <1%
Publication
Sources overview
Similarity Report ID: oid:16158:35734948
doczz.net
134 <1%
Internet
matheo.uliege.be
135 <1%
Internet
papers.academic-conferences.org
136 <1%
Internet
ESCP-EAP on 2021-11-08
138 <1%
Submitted works
Sources overview
Similarity Report ID: oid:16158:35734948
Mairi Maclean, Charles Harvey, Jon Press. "Business Elites and Corpor...
145 <1%
Crossref
Sources overview