Lectures on artificial intelligence for financial applications related to trading.
These videos demonstrate how to graph equity, bond, and energy markets using volatility and yield curve structures.
The United States spends multiple times more on defense and overseas operation than any other country. Even though these defense expenditures are important, and I do think well spent, it is important to remember that there are tradeoffs with such spending decisions. There are positive externalities with these defense expenditures, especially in aeronautics technologies. But these expenditures also have the negative effect of not having funds available for internal infrastructure projects and increased educational spending, albeit that the educational spending should be for the students and not for the pensions of the teachers’ unions. The main point relative to government spending is that there are finite resources and that such unwise decisions usually result in a less productive and growing economic condition. Government involvement overseas has produced a certain level of crowding out of domestic investment.
Geithner shows the main events in the financial crisis of 2008 in is book. What is import to notice is the steady decline in the S&P 500 before the Lehman crisis. This particular period before the crisis shows the financial stress building up from the BNP Paribas redemption issues to Fannie and Freddie conservatorships. Then the shock it with the fall of Lehman and the steady mean reversion from the signing of the Recovery Act. From a chaos theorist’s perspective the pre-Lehman signs in figure 29 were fractures that did not cause system failure by themselves but began to propagate to a threshold level that lead to a total system failure. It is my option that if we did not initiate quantitative easing that the recovery would have been for longer in the United States and far more painful in terms of unemployment and availability of credit. But it is not well know how developed economies will fare in a zero bound rate policy, e.g. Japan’s long standing stagnate economic situation as of this writing. When policy makers start to raise taxes to fill budgetary holes or when central banks start to raise interest rates there are strong headwinds fighting against such moves, which leads to lower economic growth. For example, Abenomics had to reverse course on tax policy because of recessionary concerns as of November 2014. Something similar might happen in Europe and the United States when central banks start to raise interest rates, forcing the policy makers to reverse course.
In terms of household debt, it was extremely high in 2008. Remember the middle class has been losing their percentage of national income since 1980’s. To maintain their life style middle class households started working multiple jobs, spouses entered the work force, used credit cards, and took home equity loans out. This middle class debt dynamic led to extreme household debt.
The Reagan and Thatcher doctrine of liberalization of capital markets and fiscal restructuring did help produce the great bull market of the 20th century, but at a cost. It was through this doctrine that deregulation of financial markets started.
The next big wave of deregulation of the financial industry and the adoption of the North American Free Trade Agreement (NAFTA) was in the 1990’s. This new wave of deregulation was spearheaded by the Clinton administration and the Federal Reserve Chairman.
What was so unique during the 1980’s and 1990’s that would lead to the financial crisis of 2008? Relaxed financial regulation usually causes over speculation. Financial regulation can take many forms. For example, capital flows in and out of a country can be regulated. Another type of financial regulation is the leverage ratios of banking institutions and trading margins. Another important dynamic is free trade agreements with other nations, which disrupts labor markets with the countries participating in the free trade agreement. Within these free trade agreements are free flow of capital and goods between nations. But not only did deregulation of financial markets help cause the financial crisis of 2008, but also the lack of regulation on new financial engineered products.
The derivatives market exploded exponentially in the 1990’s and 2000’s. Simple derivative markets are energy and bond markets. But more complex derivative markets were mortgage backs securities (MBS) and the close cousin—the credit default obligation (CDO). As MBS’s became more popular to reduce risk in the mortgage markets, CDO’s began to be used for reducing the default risk of the MBS owner. This complex web of derivative were not well regulated and led to over speculation in these markets many times larger than the actual annual size of the economy. This buildup of speculation in the derivatives markets eventually collapsed like all other over speculative markets in the past. The financial regulators were not equipped to survey the economic landscape and visualize the actual systemic risk building up in the financial sector.
I would like to present a few comments of the over confidence in the great moderation in the United States. The great moderation was during the tenure of Federal Reserve Chairman Greenspan. With low inflation and good economic growth the USA experienced a certain hubris that the financial engineering of Wall Street and the Federal Reserve’s fine tuning approach to interest rates could maintain a stable economy. Within this mindset, whenever the economy seemed to slow down the FED would just lower interest rates to increase aggregate demand—leading to further inflation of the speculative bubble in financial assets. Part of the orthodoxy of the Federal Reserve was that markets are efficient and that financial institutions would be rational agents. Of course markets are somewhat efficient but are clearly not rational. The failure of leading economists within the Federal Reserve and in the US government did not apply the lessons learned within the behavioral finance and economic fields of research, i.e. market participates’ fear and euphoria can outweigh any logic. In short, with the combination of deregulation of financial markets, lack of new oversight in complex engineered financial products, and the over reliance of Federal Reserve market intervention the system was primed for a major nonlinear event we all now call the crash of Lehman.
Since housing prices were not in balance with true affordability, the creation of exotic mortgages were used to keep the loan machine going. What was the incentive for the creation of these exotic mortgages? Banks no longer kept the actual loan on their balance sheet. What was going on was the securitization of mortgages and passing the actual loan risk to the buyers of a MBS. The banks received loan processing fees and MBS packaging. Therefore there was, and still is, an incentive to just process as many loans as possible without fully appreciating the systemic risk that their securitization actions were building up. This is a classic example of a feedback loop pushing the financial system into speculative equilibrium only to lead to a serious financial correction.
When too many of these types of loans from banks are going into construction of commercial or residential properties signs of an unhealthy economy emerges. This unhealthy economy is caused by over building properties and not concentrating on long term endeavors, such as loaning to actual businesses to increase production or investments in research and development. The big problem the banking industry has is that they want to loan out with as little risk as possible; therefore they usually do not have incentives to loan out to actual job creating businesses, but to property construction. Construction of property is a job creating endeavor, but only short term and I am not sure we need more major building constructions and strip malls in America. What we do need is better infrastructure and more research and development to increase our economic productivity in the long term. As can be seen in the S&P Case–Schiller composite index record housing prices coincided with record household debt. When combined, the ability to absorb a financial shock at the household level is diminished and that the risk models from the Wall Street banks and MBS holders did not fully capture the systemic risk building up in system. The key takeaway is that just because a financial engineered product can pass risk to another party there are still negative feedback loops that affect all financial participants.
What were some of the causes of the 2008 crisis? We will start a more in-depth analysis, primarily from Geithner (2014) as source material. I would suggest there were five main causes of the crisis, but there are other important causes not covered in this writing. The following five major causes are: (a) record income inequality, (b) record household debt, (c) relaxed financial regulation, (d) decline of household discretionary income, and (e) an over extension of overseas operations. With these five major causes, a confluence of factors became magnified causing the economic system to collapse. These dynamics can be explained through chaos theory.
Any one of the five major causes most likely would not bring down the whole financial system, but when added to together there are special nonlinear dynamics exhibited. As more aspects of a system are defined there are more degrees-of-freedom. With a system of high degrees-of-freedom, unexpected system dynamics result due to strange chaotic attractors. This is true even with a totally deterministic system, whereby no random functions are present in the system. In financial markets there are stochastic variations making this type of system a nondeterministic system—leading to even more strange chaotic attractions. When a certain threshold is reached a new system dynamic emerges. Let’s look at some details of the five major causes of the crisis.
In terms of record income inequality, Piketty(2014) showed that income inequality is cyclical. This cycle of income inequality in the United States can be shown over the last hundred years or so. One can conclude that very similar income inequalities exist as of this writing compared to the late 1920’s. The first big drop of income inequality was after the 1929 stock market crash. But the biggest drop in income inequality was during World War II. After the war it took approximately 4 decades for the income inequality in the United States to rise. A big part of this rise was deregulation of markets coupled with low taxation policies initiated in the Reagan and Thatcher era. More of the executive compensation, especially starting in the 1990’s, is through stock options—leading to exponential grown in income for the managerial class of workers. We see this in the average income of the executive staff of a publicly held company earning much more that the average worker—the multiple might be as high as 400 times more within some companies.
Higher income inequality might be great for a selected few in society, but it seems that this social dynamic is not healthy for the economic ecosystem. Case-in-point, from the 1940’s through the 1970’s income inequality remained stable at about 33 percent of national income for the top 10 percent of the wealthiest in the United States. During this period the middle class was growing and aggregate demand was strong. But as income inequality increased to nose bleed levels the middle class had lost approximately 15 percent of national income—primarily due to the lack of capital to participate in asset price appreciation. It is hypothesized that increased income inequality helps feed stock market bubbles, and therefore deeper stock market corrections. In chaos theory we describe this dynamic as a chaotic attraction; when one part of the system is out of equilibrium with another part of system. In this case too few people are controlling too much of the national income and leading to unhealthy economic ramifications.
Podcast on Hypercubes by Paul Cottrell.
Video lecture on Paul Cottrell's dissertation.
This book is highly recommended if you are trading currencies or are investing in European countries.
Three possible problem types can be visualized through topographic financial techniques, albeit this is not an exhaustive listing. We will look at econometric problems first. Econometric information can be very data intensive. We need a means to be able to data mine and visualize these sorts of econometric problems. One such three–dimensional dataset is unemployment, time, and gross domestic product. By having all three factors in one graph will allow for easier analysis to be accomplished. Another econometric problem is related to tax rates. By using a Laffer curve we can see how tax rates can affect actual tax revenue. But what if we wanted to understand tax rates and tax revenue over time? We can accomplish this by using topographic finance. A Laffer surface can be created, whereby the three dimensions are tax rate, time, and tax revenues. By using this sort of economic analysis, with respect to tax rates, we can determine an optimized tax policy.
The second type of problem that topographical finance can solve is visualization of financial information. In terms of fundamental analysis, financial ratios, balance sheets, and income statements can be visualized. For example, price-to-earnings ratio, revenue growth rates, and time can be inputted into a three–dimensional graph to help compare different companies to determine if an investor should invest into that company. Another example within the fundamental analysis domain is long–term debt, time, and earnings. As can be imagined, there are countless configurations to graph financial problems.
Our third example is technical or quantitative financial problems. We can utilize topographic finance by graphing price, time, and volatility; therefore allowing for an understanding of how volatility evolves through time and affects the price of an asset. Another good example is the volatility surface for an option contract. When making a volatility surface for options strike price, time-to-maturity, and volatility are used.
Again, topographic finance can graph many different types of problems and will most likely evolve into utilizing hypercubes, whereby multiple three–dimensional spaces are compared with each other to understand high dimensional dynamics. Many traders use lots of price charts with many indicators, which is utilizing hypercube faces to understand the dynamics of the market.
What is topographic finance? Topographic finance is the study of financial and economic systems in multiple dimensions, whereby three–dimensional and four–dimensional graphic technologies are used. This new financial analysis methodology provides insight that lower dimensional visualization cannot capture. Topographic finance can be used for trading and financial analysis. In figure 16 a lower dimensional visual representation is presented.
A typical financial chart has price and time. In addition to price and time, the volume of trades at a particular time frame can be represented. As you can see there is very little understanding in this example about volatility. Many traders use multiple indicators on their price chart, but the ease of reading these charts can be difficult at times, especially in fast moving conditions. There must be a better way to represent market movements in a higher dimensional way. The solution to this representational problem is the use of topographic finance.
Many option traders use volatility surfaces to understand the non–linear dynamics to the option they are trading. An option’s volatility surface contains volatility, time to expiration, and strike price. A volatility surface shows time decay of an option. There must be a way to utilize the concept of the option’s volatility surface for non–option financial products. Of course there is a solution to this problem via the utilization of topographic finance.
One can use a three–dimensional graph to see the topology of the three variables of interest. Usually this is done using the following: time, log return, and volatility. But other three–dimensional configurations can be constructed, e.g. time, correlation to another asset, and the 200-day moving average of price. It is quite easy to envision the vast amounts of different variable configurations that an economist or financial analyst can make to get a better understanding of the complexity of the non–linear dynamics of the financial markets.
Agents are the atoms of complex systems. These complex systems can be considered adaptive and exhibit emergent behavior. Agent–based modeling is a bottom–up strategy. These agents can be programmed to interact with external and internal environments. For example, researchers are using agent–based modeling to enhance stress testing in the banking sector. Standard orthodoxy for stress testing is to ask the individual banks how their balance would be affected by a ten percent reduction in assets or a thirty percent increase in loan defaults. The problem with the current orthodoxy model approach is that it does not capture a realistic contagion in the financial markets. Individually the bank many seem to pass a prescribed test, but in fact will actually fail if one considers the amplification of financial stressed counterparties. Therefore, modeling in an agent–based manner will allow for counterparty feedback loops and a more realistic simulation.
Complex behavior can emerge from agent–based modeling with just simple interaction rules. In our bank stress example, these agent rules and parameters could be total loans outstanding; payment dates and amounts between counterparties; capital reserve requirements; and short term funding rates. This might not be an exhaustive list of agent rules and parameters, but the main idea can be understood. With these simple rules the banking system will show weaker links than the current stress testing methodology—revealing that stronger banking firms might have much more counterparty risk than their risk models suggest. Through agent–based modeling of the banking sector you will notice how fragile the financial system is to asset depreciation.
Agents should be able to morph their behavior. Allowing for a morphing of behavior will add functionality to the complex adaptive system, producing a more anti–fragile system (Taleb, 2012). When banks are assessing their counterparty risks and determining what reserves are required this is a brittle strategy. They are trying to harden their balance sheet to absorb a negative shock, but this strategy does not allow them to adapt to a changing environment—leading to the needs of a lender-of-last-resort, i.e. central bank intervention. An adaptive banking system, in theory, would increase their balance sheet reserves in good times and drawdown their reserves in bad times, which reduces the need for central bank intervention.
When agents can morph their behavior, evolutionary pathways are revealed and allows for heterogeneous populations. This morphing of behavior might be in the form of agents assessing their agent neighbor’s environmental successes and trying to copy them. Within a large state–space there will be diverse groups optimized to their respective local environments.
Another promising field in agent–based modeling is the use of virtual reality. Agent–base modeling is a simulation, albeit of multiple dimensional–space. It is a natural progress to apply agents’ interactions in a virtual world, whereby a researcher can explore the interactions in an immersive way. Game developers have been programming agents in virtual worlds for many years, but usually as first-person-shooting games. To apply this gaming technology to modeling financial markets is not that hard to envision. One just needs to program the agent with certain rules and allow the different agents to interact. The virtual world it just a visualization tool to understand the complexity that emerges.