State Space Models

All state space models are written and estimated in the R programming language. The models are available here with instructions and R procedures for manipulating the models here here.

Wednesday, November 28, 2012

About

This blog applies flowgraph analysis and systems analysis to the understanding of Macrosystem models. If given enough time, I will regurgitate everything I know after 40 years of working on computer modeling of macro-societal systems. My hope is that these models can be improved in the future.

The fact that there is so much disagreement between economists is primarily because nobody has yet developed the mathematical equations and computer models needed to do really good economic predictions. I expect such mathematical equations and computer models to be developed probably sometime in the next twenty years, and certainly within the next fifty years. And sometime in the next twenty years we will probably develop a really good source of abundant energy. The problem is getting thru the next twenty years without destroying civilization as we know it. In the meantime for most of us, about all we can do is decry willful denseness--Allan Marks, 2012.

The quote above pretty clearly lays out the project. Allan Marks was responding to a blog posting by Paul Krugman (here) where economists are taken to task for supporting Austerity measures in response to economic downturns.

Here are examples of some topics that will be covered on the blog:
  • System Dynamics World Models (sometimes called Limits to Growth Models). In 1971 Jay Wright Forrester published World Dynamics. It was strongly criticized by economists (for example, William Nordhaus, here) and in a wide range of academic journals: "The study was claimed to be a piece of irresponsible nonsense, wolf crying, over-simplified and confusing, a doomsday prophesy, and a publicity stunt" (see Walter E. Hecox, 1976, here). This was the first macro computer simulation I had ever seen and the conclusions were spectacular: The world economy was going to grow rapidly until 2020 and then collapse! Whatever you think about the World I model (and I will have a lot to say about the model in later posts), if you own the book (as I do) it appears to be fairly valuable if Amazon used prices are any guide!
  • Directed Graphs, Path Analysis, Structural Equation Models and Bayesian Networks. At about the same time that Forrester published World I in the 1970's, I was working for the Social Science Computing Center at the University of Wisconsin--Madison and pursuing an interdisciplinary graduate degree housed in Sociology. Sociologists at Wisconsin were just beginning to heavily use path analysis (Arthur Goldberger and Robert Hauser were both at Wisconsin during this period jointly publishing on path models). Just after I finished my degree, I read a brutal 1982 critique of path models by Robert F. Ling in JASA (referenced here) who called it professional 'malpractice'. It was striking, then, to wake up in the year 2000 and realize that computer scientist Judea Pearl had "revolutionized the understanding of causality in statistics, psychology, medicine and the social sciences" using path models according to the ACM (here).
  • Difference Equation Models We know that single-equation difference equations can produce growth and cyclical behavior (see Goldberg, 1958). We also know that random processes summed together over time can also produce cyclical behavior (see Eugene Slutzky on random cycles here). The current controversies in economics surrounding Real Business Cycle Theories, unit roots, the role of the neoclassical growth model and random walks are, at root (no pun intended), questions about difference equation behavior. What does not seem to be well understood is how to separate the causal from the random part of system cycles.
  • Economic Growth Models Both the Neoclassical Economic Growth Model and Granger's Long Memory Series with Attractors  can be used to establish a growth path for the economy. The growth path is described as the long-run, cycle-free path. The idea of being able to define an attractor path for the economy is an important idea that seems not well integrated with current economic models.
  • Oscar Lange's Cybernetic Models Oscar Lange (1904-1965) was a Polish economist who showed that macroeconomic models can be rewritten as cybernetic models (abstract models for controlling systems) based on directed graphs and that a neoclassical model of the planned socialist economy could be developed (here). These models beg a number of questions: (1) Can the actual economic system be controlled? (2) Can we expect democratic political processes to generate control of the economy? And, (3) if we can't control social systems, what does this say for the future?
  • Impact Models One of the fundamental questions in macro modeling involves the "first-principles" from which models should be developed. In the physical sciences, the first principles are something like the laws of physics or some other fundamental physical law. Robert Kalman (see below) has argued that there are no such laws in the social sciences. One approach to first-principles would be to use identities that are true by definition. For example, in economics there is the Keynesian identity defining national income as Y = C + I + G + (X-M). Other useful identities include the I=PAT equation and the Kaya identity that measure the impacts of population growth and technological change. 
  • The Kalman Critique In 1980, R. E. Kalman (the developer of the Kalman Filter for state space systems) wrote A system-theoretic critique of dynamic economic models in an obscure and not widely available journal. Essentially, the critique argues that the dynamics of social systems are state-based rather than law like. Models based on the "laws of economics" or based on economic parameters are inadequate because neither the laws nor the parameters exist in actual social systems. The challenge is to measure the state of macro social systems. Since Kalman's critique is not very well known and since it forms the basis for my critique of economic models, a review of the paper will be one of the first posts in this blog.
  • The Wonderland Model In 1994, Warren Sanderson introduced a model to study sustainable development. The Wonderland Model had only four state variables but has become popular because it is an alternative to other models that create idealized worlds but include only economic sectors. To me, what is interesting about is not is simplified structure, which is also subject to the Kalman critique, but the visualization techniques that have been applied to analyze the model (here). The 3D phase space analysis showed three characteristic responses for the system: Dream, Horror or Escape Scenarios for economist dream, environmental collapse and environmental collapse with escape. The scenarios evolve based on various values for the parameters. The Wonderland model is interesting since economic models only follow the "dream scenario". From a technical perspective, the fact that we can only visualize three dimensional state spaces suggests that we need to reduce complex systems to lower dimensional state spaces, which is the topic of minimal realization theory in state-space analysis.
  • The DICE model In 1992, William Nordhaus developed a fully-dynamic Ramsey-type optimal growth model for studying the environmental impacts of economic development. In 1973, Nordhaus also wrote a critique of the World Dynamics models (here) and the DICE model was certainly offered as a better alternative. DICE has been very influential and has been used by the EPA (here) and Resources for the Future (here). The global DICE model has also been disaggregated into a collection of regional models (the RICE models). The RICE and DICE models are also subject to the Kalman Critique, the world-system critique, the "dream scenario" critique and the question of whether the models are any better than either world dynamics or Wonderland models.
  • Macroeconomic Models There are many types of aggregate macro-economic models (here): simple theoretical models (e.g. IS/LM), empirical forecasting models, computable general equilibrium models (CGE), dynamic stochastic general equilibrium models (DSGE) and agent-based computational models. These models are also subject to the Kalman critique and, because they can involve hundreds or thousands of equations, are subject to the Wonderland visualization critique. The models are widely used for policy purposes and beg the question of whether complex models are in any sense better than simple models.
  • Critiques By Economists Economists have not been shy about critiquing their own theory and models. An early 1976 critique by Robert Lucas titled "Econometric Policy Evaluation: A Critique" (here) suggest that econometric models must investigate deep structural parameters (preferences, technology, resource constraints) at the individual level because policy evaluation using macro models was not possible.  In 1991, Larry Summers wrote critique on the "Scientific Illusion in Empirical Macroeconomics" (here) that divided economic research into the search for deep parameters, the use of aggregate Vector Autoregressions (VAR) time series models and ad hoc empirical-historical methods that did not use models. Simmers concludes that only the ad hoc empirical-historical methods had an impact on the development of economics. Much of the critique resolves into a critique of structural equation models and causality, an issue I discussed above in relation to  Judea Pearl's work. It is important to throw these critiques at Pearl's conclusions about path models and causality to see if any stick.
  • David Easton's Political Systems Model Typically, economic policy analysis involves manipulating the exogenous variables of some complicated macro-economic model or assuming that policy makers are a representative agent (economic dictator?) whose preferences determine the future path of some macro system. David Easton, however, has argued (here) that systems theory can be applied to the analysis of political systems. Easton's work suggests another critique of macro-models: naive modeling of the political system explaining why simple-minded policy prescriptions (keep the money supply stable, increase government expenditure during a recession, etc.) fail. The political system is not a simple exogenous variable.
  • Steady State Economics Most economic models assume the "dream scenario" of exponential growth forever. These ideas have become controversial given the possible link between economic growth, CO2 emissions and climate change. To produce a future global equilibrium in 2100, for example, the DICE model has to assume that technological change and population growth arbitrarily come to a halt (they are the two exogenous variables for the model). From the world dynamics perspective, uncontrolled exponential growth was seen as the major problem creating environmental collapse. For the economic perspective, Herman Daly has offered the most detailed analysis of steady-state (sustainable) economies. His thinking does not seem to have influenced any macro-economic models but needs to be carefully considered.
  • How to Evaluate models and determine the "best" model One part of the Kalman Critique is that for any given set of data there can be only one best model. There cannot be a world dynamics model, an ImPact model, a Ramey-type optimal growth model, a CGE and a DSE model. A measure developed by Hirotugu Akaike (the AIC or Akaike Information Criteria) has been offered as a criterion. Basically, the best model is the simplest model that explains the data with the smallest error. The simplicity criterion is sometimes called Occam's Razor. Unfortunately, most macro models never report an AIC. Until that happens, the best a researcher can do is to develop multiple models that address competing theoretical issues, test them together and apply the AIC to each model choosing the best model with the smallest AIC i.e., smallest departure from the data correcting for the model's size. The process is called multi-model inference (here and here). There is still a lot to learn from the exercise and it could be argued that models which do not report an AIC are not worth considering as serious competitors.
  • Modeling vs. Experimental Sciences Neither the Solar System nor macro-societal systems can be studied through experimental methods. Natural experiments, where some exogenous event changes, can produce quasi-experimental conditions but not the kind of control that would be applied to, for example, a clinical trial. This critique has been most forcefully made for path models (see Freedman's 1987 critique of path models here) which are essentially visual representations of the kind of structural equation models that are used in all formal macro models. Multi-model inference provides an answer to this critique, but we need to fully understand the critique to make the argument.
  • Stability, Observability and Controlability in Social Systems The arguments about uncontrolled exponential growth and the possibility of exerting policy control over macro-economies can be resolved to another aspect of the Kalman critique. Kalman argues that techniques within control theory can be used to assess these issues. Unfortunately, the analysis applies only to models and to state-variable models at that, rather than to real systems. It turns out that minimal realization theory provides a formal answer to the problem of reducing complex models to state-space form. The theory also suggests that much of the complex structural modeling could be bypassed. The theory also suggests that the ability of stable systems to deal with disorder (anti-fragility) should be an important attribute of social systems.
  • World Systems Theory When I wrote my dissertation in 1980, I wasn't aware of World-system Theory (WST), but I should have been. WST takes a premise from Hierarchal Systems Theory (HST) arguing that the world system is organized in a hierarchy of nations with core, semi-peripheral and peripheral nations. To hierarchical organization, WST adds four temporal features: secular trends, cyclical rhythms, contradictions and crises. WST is not yet a very quantitative discipline, but I think that WST and General Systems Theory (GST), which is quantitative, could be easily combined.
  • Hierarchical Systems Theory HST is a quantitative area that deals with communication and control between systems organized in a hierarchy, that is, a hierarchical control system. Applying HST to nation states allows WST to be extended in quantitative directions.
  • General Systems Theory GST was originally developed for studying living systems where concepts such as feedback, regulation, growth, stability and isomorphism proved useful.  The same concepts could be usefully applied to the world system.
  • Societal Collapse There have been a number of highly developed human societies that have collapsed: the Mayan Civilization, the Roman Empire, the Han Dynasty in Asia, etc. Insights from these historical studies could supplement the concept temporal crises in WST. The extension is particularly important since some of the collapses were the result of environmental factors and the IPCC Emissions Scenarios have deliberately not included the possibility of societal collapse.
  • Malthusian and Neo-Malthusian Theory The Limits-To-Growth models and other models that have included environmental sectors have been described as Malthusian or neo-Malthusian after the work of Thomas Malthus. Kenneth Boulding, in his introduction to Population: The First Essay (here) has described the Malthusian model as  "...irrefutable as a syllogism...," that is, if population grows beyond the means of subsistence, the result will be a Malthusian Catastrophe. A syllogism would provide another useful first principle from which theory can be developed. It's also the case the neo-classical economic growth model assumes that both population growth and technological change are exogenous, meaning the economy can always avoid a Malthusian crisis. Is this wishful thinking, especially since growth models are not based on irrefutable first principles?
  • Globalization, Biodiversity and Ecological Footprint One problem with macro modeling already mentioned is the problem of complexity. Real social systems are infinitely complex while quantitative models require simplification. One way to reduce complexity is through the use of indexes that summarize important parts of a macro-system. Three important such indexes are the KOF Index of Globalization, the Living Planet Index (a measure of biodiversity) and the Ecological Footprint Index (a measure of human demand on the Earth's ecosystems). Each of these indexes is surrounded by a swirl of controversy. I will argue that state-space measurement theory could resolve many of the issues.
  • Peak Oil Energy is a critical input to economic (and political) systems that often seems lost in the sources of economic growth debate. without coal during the 19th Century and Oil During the 20th entry, economic growth trends without doubt would have been very different. Peak Oil, on the other hand, is the point where the maximum rate of oil extraction is reached. There is a lot of argument about whether peak oil will ever be reached but if it was the path of economic growth would change. The problem is that current economic growth models neither predict nor take peak oil into account.
  • IPCC scenarios The SRES (Special Report of Emissions Scenarios) published by the IPCC are an attempt to describe alternate futures for the Global Climate System. The SRES does not seem to make use of any insights from WST GST or HST.
This is a long list of issues that need to be discussed if the quality of macro models is to be improved. The first stop on this adventure will be the Kalman Critique.