Prediction of Financial Crisis with Artificial Neural Network: An Empirical Analysis on Turkey

Prediction of economic crisis, financial distress or bankruptcy has attracted great deal of attention in financial literature and in many other fields among the researchers over the past few decades. Although there are a variety of different methods that can be used to predict the future financial crisis, due to the complexity of the existing factors, prediction of financial crisis is a very difficult case. With the advent of Artificial Neural Networks (ANNs), researchers had the chance to solve various problems in finance. ANN approach is the application of artificial intelligence, which has been improved by the simulation of cognitive learning process of human brain. ANNs are commonly used in recent years, due to major advantages that they offer such as their ability to perform nonlinear statistical modeling that provides new alternative to other statistical methods and to learn directly from examples without needing or providing an analytical solution to the problem. In this study, a monthly dataset covering the period of 1990 and 2014 that belong to the Turkish economy will be used. The purpose of this study is to develop an early-warning system to predict financial crisis. To realize this aim, multi-layered feedforward neural networks (MLFNs) will be used. By using monthly data of 7 key macroeconomic and financial indicators of Turkish economy during 1990 and 2014, we find that predictive power of ANN is quite striking. Our out-of-sample forecasts indicate that the Turkish economy remains at high risk due to major negative developments and potential political instability between 2014 and 2016.


Introduction
The integration of financial markets and the globalization all around the world exposed policy makers to new challenges as a results of shortening of the time period that policy makers should respond to global financial crises. Past crises indicated that financial markets are reasonably poor at realizing a crisis approaching. Therefore, as Cheng et al. (2006) point out, prediction of economic crisis, financial distress or bankruptcy has attracted great deal of attention in financial literature and in many other fields among the researchers over the past few decades. The recent financial crisis of 2008 has revealed great weaknesses in financial system and inadequacy of financial regulations. After big corporate scandals and the demise of giant companies like Arthur Anderson, Enron or Worldcom, global economies and people all around the world have been extremely cautious about the potential early warning signs of financial system. Since the beginning of the recent financial crisis in 2008, investors and lending institutions experienced enormous financial lossess.
A financial crisis is a certain economic state in which economic, social and political deteriorations create uncertainty and chaos in the society. Many factors can be specified as causes of financial crisis including excessive risk taking, poor management practices, inadequate internal control mechanisms, and interest rate volatility (Ecer, 2013). While the people and societies, who cannot predict the financial crisis had to suffer from unemployment, poverty and a variety of other economic problems, those who can anticipate the crisis can use it to their advantages and transform the potential drawbacks into opportunities. Therefore, prediction of financial crisis and developing an evolutionary approach sufficient for handling with dynamic financial circumstances are utmost important among policymakers, governments, regulators, researchers and global investors. If they can succeed, by utilizing the early warning systems, governments can monitor the financial system and take precautions to protect their societies from new financial crisis.
Additionally, an early warning system might also be useful in determining the vulnerability of a group of countries, which would be more difficult to evaluate. By identifying which countries are more vulnerable in a period of global financial crises, policy makers would be able to focus their attention on the countries that need radical policy adjustments to prevent a crisis. Thus, early warning systems can support regulators and policymakers to protect their markets from economic crisis.
Empirical research on developing early warning systems has been relatively new. Although there are a variety of different methods that can be used to predict the future financial crisis, due to the complexity of factors, prediction of financial crisis is still a very difficult case. As Yildirim et al. (2011) state, researchers generally benefit from a variety of different statistical methods to analyze data, establish models and make decisions based on their estimations to conduct their reseraches. In the last few decades, as studies aimed at predicting the financial crisis have become more common, machine learning has also been widely used among researchers to realize this goal.
With the advent of Artificial Neural Network (ANN) researchers had the chance to analyze various problems in finance such as prediction of potential financial crisis. ANNs have been frequently used in the field of finance. Recently, they have become popular tools to assist financial decision making. As Oztemel (2003) points out, there are many different areas of research in finance in which ANNs are used such as credit authorization and screening, credit risk assessment, project management, financial and economic forecasting, fixed income investments, prediction of default and bankruptcy and credit card manipulations. Additionally, use of ANNs can significantly improve the following corporate finance applications such as financial simulation, investor behavior prediction, portfolio management, pricing initial public offerings, determining optimal capital structure, financial evaluation and credit approval (Bahrammirzaee, 2010).
The reminder of the study is organized in the following way. We discuss the literature focusing on the studies based on the ANNs and the alternative techniques in section 2. We describe the data set and methodology in Section 3. In this section, we also give brief information about the structure of ANN. In section 4, we present the results concerning the relationship between the real values and the obtained values from the ANN. Section 5 is the conclusion part of the study.

Literature Review
Since the beginning of 1990s, ANNs have been frequently used to solve complicated problems and assist many business applications successfully. They can be utilized as efficient tools to analyze critical issues in business decisions. As Ecer (2013) states, real world financial data have often been nonlinear recently. However, thanks to latest developments in computing technology, nonlinear models can also be used in modelling and forecasting myriad of financial relationships. In this context, ANNs also help to solve problems in finance with poorly defined models.
Although developing a common model for all types of financial crisis is very difficult, it is possible to build an early warning system that would pick up different variables. Many researchers prefer to utilize ANN to conduct their studies. However, only limited number of researchers use ANN in their empirical investigations to identify financal distress or predict financial crisis. In one of the earliest studies, Bell et al. (1990) employed BPN technique by using eleven predictor variables to classify whether selected banks are bankrupt or not. They compared the performance of a logit model with the ANN performance and concluded that ANN was better than logit in determining marginally distressed banks. Tam and Kiang (1992) compared the BPN technique with multivariate discriminant analysis (MDA) and logit to predict bankruptcy of selected Texas banks by using nineteen financial ratios to develop their models. Their results indicate that BPN technique is more accurate in predicting bankruptcy rates of banks. Brockett et al. (1994) also utilized BPN technique and multivariate discriminant analyssis (MDA) to identify early warning signals of insurer insolvency. They conclude that BPN technique has a higher success in classifying insolvent or solvent firms.
The most important difficulty, which may be experienced in the prediction of financial crises is on the determination of which variables should be selected among a great number of data to be included into the models. Kaminsky, Lizondo and Reinhart (1998) have picked up the most useful variables to be used in the prediction of the financial crises by seperating out 16 variables out of 103 indicator variables. For all of the variables, the indicator on a given month was defined as the percentage change in the level of the variable with regard to its level in the previous month. At the same time, these indicator variables can be evaluated as a signal for anticipating crisis. Genarally, a signal that is followed by a crisis within 24 months is named as a good signal, whereas a signal not followed by a crisis within the mentioned period of time is called a false signal. Nag and Mitra (1999) used the ANNs to establish an early warning system to detect exchange rate crisis over the period of 1980-1998 in Indonesia, Malasia and Tayland. They employed sixteen variables for their study. They compared their results with the results obtained by the signal approach. They found that the ANN model has a superior ability of prediction as compared to the signal approach. Frank and Schmied (2003) utilized the ANNs in the prediction of speculative attacks. They investigated the speculative attacks in Russia and Brazil experinced in 1998 and 1999. According to them, trying to determine the nonlinear relationships by using linear models weakens the possibility of the prediction of financial crisis. For that reason they state that they used ANNs in their study and conclude that ANN has a more accurate performance as compared to the logit models in the prediction of speculative attacks. Oh et al. (2005) used the ANN model and the method of Nonlinear Programming (NLP) together to predict the 1997 financial crisis within the framework of Korean example bu using the early warning systems. The major difference of the study from the previous studies is that the researchers used daily data and established alarm zones by using financial crisis prediction variables. Peltonen (2006) aimed to predict monetary crisis in developing countries by using ANN and probit models. In the study, the monthly data for twenty four emerging market countries over the period of 1980 and 2001 were used. They obtained 45% of successful prediction levels in both models prior to financial crisis. Fioramanti (2008) in his study, tried to predict the debt crisis in less developed countries by using the data that belong to the period of 1980 and 2004 by employing the ANN model. He asserts that the ANN model can obtain more accurate results as compared to other early warning systems thanks to its high flexibility and its ability to analyze the nonlinear relationships. In his study, he used yearly data of 46 developing countries that belong to 34 independent variables over the period of 1980 and 2004. Similar to the results of Nag and Mitra (1999) and Franck and Schmied (2003), Fioramanti (2008) observed that the ANN model provided more accurate and successful results.
Implementation of ANN models in Turkey also provided similar successful results. Various researchers used ANNs such as Yıldız (2001) and Benli (2002) to predict financial failures; Çelik and Karatepe (2006) to predict banking crises; Tektaş and Karataş (2004) to predict stock prices; Benli (2005) to predict bank failures; and Erilli et al. (2010) to predict inflation rates.

Artificial Intelligence Techniques
Artificial intelligence techniques are used in a variety of fields and new techniques are being developed every day. As Oztemel (2003) classifies major artificial intelligence techniques include:  Expert Systems: They are computer systems which can produce results to the problems just as a human expert can do. They are equipped with knowledge of expertise to solve complex problems. Inference mechanisms make decisions by establishing relationships between data.  Artificial Neural Networks (ANNs): They are a type of statistical learning algorithms which resemble biological neural networks. They are used to estimate functions that can depend on a large number of inputs and are generally unknown.  Genetic Algorithm: They are adaptive heuristic search algorithm developed to solve problems which cannot be solved with the traditional optimization technology. They are based on the ideas of natural selection and genetics. They benefit from historical information to direct the search to obtain beter performance in the search space. They are based on the philosophy of combining solutions of the problems to provide beter solutions.  Fuzzy Logic: It is a type of logic that recognizes more than simple true and false values. With fuzzy logic, propositions can be represented with degrees of truthfulness and falsehood, which eases decision making process.

The Structure of Artificial Neural Networks (ANNs)
The neural networks principally match inputs to the outputs by utilizing layers and neurons to create a complex learned algorithm. The artificial nevre cells come together and compose the artificial neural networks. They do not join together randomly. Usually, the nevre cells come together in three layers, in paralel with each other in each layer and they constitute the network. (Oztemel, 2003) Thus each of the layers is comprised of many neurons that are connected to the neurons in the preceding and subsequent layers. These layers are (Muller et al., 2009):

Empirical Results
In this study, we assess the relative performance of forecasting model based on the multi-layered feedforward neural network (MLFN). MLFN, which is also known as "backpropagation network" is one of the most widely used ANN in financial researches. Basically, the structure of MFLN consists of an input layer, one or more hidden layers depending on the result of the study and the output layer of processing units. One of the major decisions that the developer of a neural network may encounter is the number nodes in a hidden layer. No theory or a formula exists to determine the optimal number and therefore, network developers need to use the method of trial and error to find the optimal number of hidden nodes.
The layers in the structure are interlinked with each other that the processing units in the input layer are connected to the units in the hidden layer. The units in the hidden layer are connected to the units in the output layer respectively. For any structure with multiple hidden layers, the first hidden layer which transmits information from the input layer is linked to the second hidden layer. Rest of the hidden layers are connected similarly and consequently, the last hidden layer sends the processed information to the output layer. MLFN with supervised learning can be used to develop nonlinear models to indicate the relationship between the independent and the dependent variables. (Chen and Leung, 2005) In this paper, the data of 298 months between January 1990 and September 2014, obtained from the internet sites of Electronic Data Distribution System of the Turkish National Bank (EDDS) and The World Bank, were used. In the empirical analysis part, seven different variables, which are US Dollar (USD), gold prices (GP), Borsa Istanbul (BIST) 100 Index, wholesale price index (WPI), money supply (MS), domestic debt stock (DDS), composite leading economic indicators index (CLEI) were used. In the prediction of the next 24 months of crisis indicator data in Turkey, we prefer to use feed-forward, backpropagation, multi-layered ANN. Testing was performed by the JAVA programming language. Obtained models have investigated whether the data will show a decrease or increase in comparison with previous or latter month.
In this study, in terms of applied method, a feed-forward and multilayered ANN has been used which is composed of 7*12=84 inputs, 7 outputs and 2 hidden layers in which 25 neurons are included in each layer. In the layers of the network, the sigmoid activation function has been used. The artificial neuron output value, which depends on the selected sigmoid activation function, is calculated with Eq. 1. The generated output is sent via the connections of the network to the other cells (Sagiroglu et al., 2003)  In addition to this, the resillient propogation learning algorithm has been used for the learning of the network. In this learning proces, the error value of 0.1 % has been chosen as a target value which provides a limit between the desired values. In the structure of a multi-layered ANN, there are mainly three layers. An input layer with artificial neural cells, which are connected to each other in different ways, a hidden layer (intermediate layer) and an output layer. In Figure 1, a three layer network structure, artificial neurons and inter-layer relations have been demonstrated schematically. The input layer which is composed of 84 (7*12) data is the first layer and is responsible for receiving incoming data to the ANN. It also serves to distribute the incomimg data to the intermediate or hidden layer. The

Figure 1. A brief depiction of the proposed methodology for ANN
Because of easiness in its utilization, time series which take part in ENCOG framework, have been given preference in the Temporal Neural Dataset class of software that are constituted for the data sets. Additionally, we have benefited from several strategies in order to assist coding in the framework such as "If certain number of iterations have been passed in the training of the network, restart to learning" or If the error value does not progress a significant proportion, restart to learning.
The normalization and the denormalization of data have been done with the help of built-in functions found in framework. While the network is being trained, the twelve-month lagged values of data were given as prologue and forecasting of the thirteenth month has been demanded. In the same manner, it has been tried to be estimated starting from the 36th month of 299 months that are in the data set. For each month to be predicted, ANN has been trained iteratively with its previous three-year data. For the 300th and the following months, again its previous three-year data has been given to the ANN as training set and the missing months have been filled by the prediction values obtained in previous iterations.
In an economic environment in which capital movements have been liberalized, Turkey experienced the crises of 1994 and 2001. Both crises had few common points such as large amounts of capital inflows and capital outflows before and after both crises. In the aftermath of 1994 crisis, financial risks in banking sector increased rapidly due to the state guarantee on bank deposits. The overvaluation of Turkish Lira and the rapid rise in interest rates could not be evaluated adequately and this resulted in the 1994 financial crisis. During the period of 1995-1999, the potential crises and disparities were tried to be avoided by taking a variety of measures of precautions. However, risk perceptions in Turkey also changed in paralel to the financial crises experienced in different parts of the world in 1998 and capital outflows also accelarated.
When the graphics presented in Figure 2 are reviewed in detail, especially, as a consequence of the interest rates discounted by government in 1993, funds tended to move towards foreign currency and stock exchange. Consequently, foreign exchange rates have risen in parallel to this. Besides, DDS attained to its the peaking limit for the first time in its history. It reached to a point that tax revenues could not defray the payments of domestic borrowings.
All the negative developments in economy such as the overvaluation of Turkish Lira, the boom of gold prices, the jump of the stock market, the overshooting of wholesale price index (especially, on December of 1999), the rise of USD in the final half of 1999, and political uncertainities all caused the most severe financial crisis in the history of Turkey, the economic crisis of 2001. Analyzing the predicted data in terms of financial crisis in Turkey, especially during the 2001 financial crisis, we see that indicator variables either sharply increase or decline. These fluctuations clearly reveal the impacts of the 2001 financial crisis on the Turkish economy. The period of 2002 and 2007 is a stability period, thanks to structural reforms applied in Turkish economy and the financial system, and the positive course of events in the global economy. This stable period provided high growth rates in Turkish economy until 2008. In this time period, the average growth rate of Turkish economy was 7% and the avreage increase in exports was 23%. The relation between the values calculated with the prediction model concerning the training, validation and test data and the real values can be seen in Figure 2. And the prediction of the data from 2014.12 to 2016.11 is given in Table 1. Figure 2 shows that the predicted ANN model has a stronger explanation abilities for the 2001 and 2008 crises. This figure also clearly indicates that the rapid economic growth during the periods between 2002-2004 and 2005-2007 have been accompanied by accelerated increases in macroeconomic and financial risks.
2008 financial crisis, the first global financial crisis of the world, has had a deep negative affect initially on developed countries and later on emerging countries. Turkey is one of these developing countries which have been affected considerably from this crisis. As a result of the approaching crisis, the high growth rates in the economy slowed down and the Turkish economy had a negative growth rate in 2009. Undoubtedly, 2008 financial crisis had negative affects on the growth rates of all economies. However, the level of contraction in the economy has been extensive on the European countries and on Turkey. The crisis was severely felt in the emerging economies, mainly because of reductions in the amount of capital flows from developing to the emerging markets. As a consequence of falling demands from the developed countries, the exports of emerging countries like Turkey to the developed markets sharply declined. Unemployment rate, one of the most important indicator of the financial crisis, remains as a social and economic problem that should be solved in developed countries as well as in emerging countries.

Conclusion
It is difficult to forecast the share prices in countries like Turkey, which have many manipulative changes in its economic structure. Especially in less developed or developing countries like Turkey, political and economic uncertainities affect macroeconomic politics intensely. In spite of the fact that some researchers claim that they are successful in predicting financial crisis, the remarkable differences among the incidences of such crisis in the world suggest that these incidences are hardly predictable in a systematic manner.
This paper is one of the first applications of the ANNs for the literature of prediction of financial crisis. Furthermore, factors affecting financial crises were evaluated with a special focus on the economic fundamentals obtained from the financial crises theories, as well as factual exchange rate regime and contagion effects. By using monthly data of 7 key macroeconomic and financial indicators of Turkish economy during 1990 and 2014, we find that predictive power of ANN is quite striking. Our out-of-sample forecasts indicate that the Turkish economy remains at high risk due to major negative developments and potential political instability between 2014 and 2016. Although we have obtained some interesting results, we are aware that prediction in a complex and dynamic social system is indeed a very difficult task that calls upon more advanced and sophisticated techniques of computational intelligence. In addition, how to incorporate qualitative data such as contagion, political disturbances and moral hazard into intelligent decision systems remains an open question.
Although, the number of related studies on the prediction of financial crises is highly limited in Turkey, as a suggestion for further research, such studies could be conducted for other business sectors, too. As such, managers, policymakers and researchers can develop long-term plans and make better decisions in critical conditions. Consequently, long-term forecasting will contribute positively to the Turkish economy as a first step of stability in economy and in business.
To sum up, as many studies in the literature indicate, the ANN has superior performance in the prediction of financial crises to develop an early warning system. It is noteworthy that certain economic variables that are associated with the financial crises of 1990s and the economic fundamentals derived from the financial crisis theories were capable of explaining the threshold of the financial crises. In contrast, in the 2000s, other factors, such as the contagion effect and the instable foreign exchange regimes, seem to have played a larger role in the occurrence of these crises. This reinforces the view that developing a stable model that could predict or even explain financial crises by using ANN or other alternative methods can be challenging but also invaluable for the global economy in general.