Biological Dynamics of Stress Response

At ISDC 2018, we gave the Dana Meadows Award for best student paper to Gizem Aktas, for Modeling the Biological Mechanisms that Determine the Dynamics of Stress Response of the Human Body (with Yaman Barlas)This is a very interesting paper that elegantly synthesizes literature on stress, mood, and hormone interactions. I plan to write more about it later, but for the moment, here’s the model for your exploration.

The dynamic stress response of the human body to stressors is produced by nonlinear interactions among its physiological sub-systems. The evolutionary function of the response is to enable the body to cope with stress. However, depending on the intensity and frequency of the stressors, the mechanism may lose its function and the body can go into a pathological state. Three subsystems of the body play the most essential role in the stress response: endocrine, immune and neural systems. We constructed a simulation model of these three systems to imitate the stress response under different types of stress stimuli. Cortisol, glucocorticoid receptors, proinflammatory cytokines, serotonin, and serotonin receptors are the main variables of the model. Using both qualitative and quantitative physiological data, the model is structurally and behaviorally well-validated. In subsequent scenario runs, we have successfully replicated the development of major depression in the body. More interestingly, the model can present quantitative representation of some very well acknowledged qualitative hypotheses about the stress response of the body. This is a novel quantitative step towards the comprehension of stress response in relation with other disorders, and it provides us with a tool to design and test treatment methods.

The original is a STELLA model; here I’ve translated it to Vensim and made some convenience upgrades. I used the forthcoming XMILE translation in Vensim to open the model. You get an ugly diagram (due to platform differences and XMILE’s lack of support for flow-clouds), but it’s functional enough to browse. I cleaned up the diagrams and moved them into multiple views to take better advantage of Vensim’s visual approach.

The model ran right away, though I had to add one MAX statement to handle a uniflow (not supported in Vensim, and something I remain allergic to). There’s actually an important lesson on model replication and calibration in this.

When I first translated the model, I ran a few scenarios, using the comprehensive replication instructions in the supplemental material for the paper. I built up a Vensim command script to make it easy to replicate all the scenarios in the paper. To do that, I had to modify the equations a bit, so that manual equation editing (in STELLA) could be replaced by automatic parameter changes.

Then I ran my script and eyeballed a few graphs. Things looked pretty good:

The same, right? Not so fast! If you look closely, you’ll find that the Vensim version (bottom) has 9 peaks instead of 10, due to my replacement of a cascade of IF … ELSE test inputs with a simpler PULSE TRAIN. When you fix the count, there are still issues, because the duration parameter for each pulse (0.2) is not an integral multiple of the TIME STEP. (Incidentally, differences arising from PULSE implementations are tricky – see Yutaka Takahashi’s poster from ISDC 2018).

It took me several iterations to work out what was going wrong. I found that, to really verify that the translation (plus my initially erroneous upgrades) was OK, I had to export a run from STELLA, import it as a dataset in Vensim, and compare behavior hour by hour. That’s how I discovered the subtle but important uniflow difference.

The fact that tiny differences in test input implementations matter highlights the extreme numerical sensitivity of the model. This is a feature, not a bug. It arises from positive feedback that creates sensitive thresholds in stress response: 5% more episodic stress can be the difference between routine recovery and total collapse.

For example, here’s a sensitivity experiment with external stress at 10, 20, 30, 40, 50 & 60 units:

Notice that for external stress <= 40, recovery is quick – hours to days. But somewhere above 40 is a nonlinear threshold, beyond which recovery takes weeks.

This .zip archive contains:

  • An updated source model (.stmx) from the author, used for the translation.
  • The translated model (.mdl and .vpm). This version won’t work in PLE because it uses macros, but you can use the free Model Reader to run it.
  • Command scripts for replicating the paper’s scenarios, plus the vector of stress levels above.

StressResponseModel_converted 7.zip

Update: StressResponseModel_converted 7b.zip fixes a unit error in a test input (my mistake) – this version is closest to the original in the paper.

Update 2: StressResponseModel_converted 8.zip has an improved control panel and runs 4x faster. It departs from the original to improve sensitivity analysis capability and pulse test stability, but remains dynamically identical (as far as I can determine).

The original paper and supplementary material should be in the conference submission system.

Stay tuned for more on this topic! Here’s a detailed critique & analysis.

Are We Slaves to Open Loop Theories?

The ongoing bailout/stimulus debate is decidedly Keynesian. Yet Keynes was a halfhearted Keynesian:

US Keynesianism, however, came to mean something different. It was applied to a fiscal revolution, licensing deficit finance to pull the economy out of depression. From the US budget of 1938, this challenged the idea of always balancing the budget, by stressing the need to boost effective demand by stimulating consumption.

None of this was close to what Keynes had said in his General Theory. His emphasis was on investment as the motor of the economy; but influential US Keynesians airily dismissed this as a peculiarity of Keynes. Likewise, his efforts to separate capital projects from ordinary budgets, balanced if possible, found few echoes in Washington, despite frequent mention of his name.

Should this surprise us? It does not appear to have disconcerted Keynes. ‘Practical men were often the slaves of some defunct economist,’ he wrote. By the end of the second world war, Lord Keynes of Tilton was no mere academic scribbler but a policymaker, in a debate dominated by second-hand versions of ideas he had put into circulation in a previous life. He was enough of a pragmatist, and opportunist, not to quibble. After dining with a group of Keynesian economists in Washington, in 1944, Keynes commented: ‘I was the only non-Keynesian there.’

FT.com, In the long run we are all dependent on Keynes

This got me wondering about the theoretical underpinnings of the stimulus prescription. Economists are talking in the language of the IS/LM model, marginal propensity to consume, multipliers for taxes vs. spending, and so forth. But these are all equilibrium shorthand for dynamic concepts. Surely the talk is founded on dynamic models that close loops between money, expectations and the real economy, and contain an operational representation of money creation and lending?

The trouble is, after a bit of sniffing around, I’m not seeing those models. On the jacket of Dynamic Macroeconomics, James Tobin wrote in 1997:

“Macrodynamics is a venerable and important tradition, which fifty or sixty years ago engaged the best minds of the economics profession: among them Frisch, Tinbergan, Harrod, Hicks, Samuelson, Goodwin. Recently it has been in danger of being swallowed up by rational expectations, moving equilibrium, and dynamic optimization. We can be grateful to the authors of this book for keeping alive the older tradition, while modernizing it in the light of recent developments in techniques of dynamic modeling.”
’”James Tobin, Sterling Professor of Economics Emeritus, Yale University

Is dynamic macroeconomics still moribund, supplanted by CGE models (irrelevant to the problem at hand) and black box econometric methods? Someone please point me to the stochastic behavioral disequilibrium nonlinear dynamic macroeconomics literature I’ve missed, so I can sleep tonight knowing that policy is informed by something more than comparative statics.

In the meantime, the most relevant models I’m aware of are in system dynamics, not economics. An interesting option (which you can read and run) is Nathan Forrester’s thesis, A Dynamic Synthesis of Basic Macroeconomic Theory (1982).

Forrester’s model combines Samuelson’s multiplier accelerator, Metzler’s inventory-adjustment model, Hicks’ IS/LM, and the aggregate-supply/aggregate-demand model into a 10th order continuous dynamic model. The model generates an endogenous business cycle (4-year period) as well as a longer (24-year) cycle. The business cycle arises from inventory and employment adjustment, while the long cycle involves multiplier-accelerator and capital stock adjustment mechanisms, involving final demand. Forrester used the model to test a variety of countercyclic economic policies, commonly recommended as antidotes for business cycle swings:

Results of the policy tests explain the apparent discrepancy between policy conclusions based on static and dynamic models. The static results are confirmed by the fact that countercyclic demand-management policies do stabilize the demand-driven [long] cycle. The dynamic results are confirmed by the fact that the same countercyclic policies destabilize the business cycle. (pg. 9)

It’s not clear to me what exactly this kind of counterintuitive behavior might imply for our current situation, but it seems like a bad time to inadvertently destabilize the business cycle through misapplication of simpler models.

It’s unclear to what extent the model applies to our current situation, because it doesn’t include budget constraints for agents, and thus doesn’t include explicit money and debt stocks. While there are reasonable justifications for omitting those features for “normal” conditions, I suspect that since the origin of our current troubles is a debt binge, those justifications don’t apply where we are now in the economy’s state space. If so, then the equilibrium conclusions of the IS/LM model and other simple constructs are even more likely to be wrong.

I presume that the feedback structure needed to get your arms around the problem properly is in Jay Forrester’s System Dynamics National Model, but unfortunately it’s not available for experimentation.

John Sterman’s model of The Energy Transition and the Economy (1981) does have money stocks and debt for households and other sectors. It doesn’t have an operational representation of bank reserves, and it monetizes the deficit, but if one were to repurpose the model a bit (by eliminating the depletion issue, among other things) it might provide an interesting compromise between the two Forrester models above.

I still have a hard time believing that macroeconomics hasn’t trodden some of this fertile ground since the 80s, so I hope someone can comment with a more informed perspective. However, until someone disabuses me of the notion, I have the gnawing suspicion that the models are broken and we’re flying blind. Sure hope there aren’t any mountains in this fog.