370 likes | 499 Views
Dynamics of Contagion: Comparing Agent-Based and Differential Equation Models. Hazhir Rahmandad and John Sterman MIT-Albany Colloquium April 30, 2004. Motivation. Agent Based (AB) models are widespread: e.g. Santa Fe, Wolfram’s A New Kind of Science
E N D
Dynamics of Contagion: Comparing Agent-Based and Differential Equation Models Hazhir Rahmandad and John Sterman MIT-Albany Colloquium April 30, 2004
Motivation • Agent Based (AB) models are widespread: e.g. Santa Fe, Wolfram’s A New Kind of Science • Many exciting applications, but lots of hype, not enough understanding of when AB adds value and when it is inappropriate • Question is not ‘which type of model is right?’:All models are wrong. • Question is • Which type of model is best suited for different purposes? • How robust are policy conclusions to modeling methods? • How can best attributes of both modeling paradigms be integrated?
DE vs. AB: What are the differences? • Differences in typical assumptions: • Level of aggregation of similar elements • Treatment of Time • Continuous (solved numerically, results (should be) insensitive to time step or numerical integration method) • Discrete (time periods often undefined, can’t easily be varied) • Differences in typical practice • Modeling problems vs. modeling systems • Emphasis on stochastic elements • Software and representation
Translating SEIR into AB C[J,k]=IF(S[J]*CP[J,K]*IP[K], CR[J,K]>Rn[J,K],1,0) CP[J,K]=LCR[J,K]*DT IP[J]= E[J]*IES+I[J]*IIS CR[K]=S[K]+CE/CS*E[K]+CI/CS*I[K]+CR/CS*R[K] LCR[J,K]=f(NW[J,K], CS, K, a, TUL[J]*TUL[K])
AB SEIR Overview • # of States: N*4 vs. 4, • N=200: Total # of variables and parameters: over 300000 vs. 35
Experimental Design • AB SEIR Settings: 10 combinations (5*2) • Network Structure • Uniform, Random, Scale-Free, Small-world, Lattice • Heterogeneity • Low and High • N=200 • Simulating each setting 1000 times • Comparing with Base DE and Calibrated DE on 3 measures of Diffusion Fraction (F), Peak Time (TP) and Peak Value (IMAX)
Networks: Random & Uniform • Uniform: Everybody is connected to everybody else • Random: There is a random network structure (same chance for all possible links)
Networks: Scale Free • The number of links has a power law distribution • A few hubs with lots of links and a lot of poorly connected individuals
Networks: Small-world & Lattice • Small world, with k expected links: • Expected links to neighbors with distance up to k/2: k*p • Connected to k/2-far neighbors with probability p • Expected long distance links: k*(1-p) • Connected to others with k*(1-p)/(N-k) • Lattice: No long distance link
Heterogeneity • Contact Rate[J,K]= • Low • More link for individual (N) =>Proportionally less contact per link (α=1) • Fixed individual tendencies to use links (TUL[J]=1) • High • Contact per link independent of individual connectivity (α=0) • Uniform distribution of TUL ~U(0.25-1.75)
Calibration • Optimized DE is more realistic than base DE • Best fitting DE model matching MEAN Infected in AB simulation • Optimize over • Infectivity of Exposed and Infectious (0<CE,CI) • Average Incubation Time (0<ε<30) • Average Duration of Illness (5<δ<30)
Populations Susceptible Recovered 200 150 F=( S0-S∞)/ S0 S0-S∞ 100 Exposed Infectious S0 50 Imax 0 0 30 60 90 120 150 180 210 240 270 300 Time (Day) Tp A typical simulation
Results: Calibration Insights • Very good fit: 0.97<R2<1.00 • Calibrated parameters absorb networks and heterogeneity effects
Results Summary • Effect of Network small except lattice • Some Numerical, Little Behavioral Sensitivity • Clustering increases AB-DE gap • Network size decrease AB-DE gap • No gap with calibrated DE • Effect of heterogeneity small • Extreme: Disintegration into social and hermit (Scale-Free shows best) • The AIDS example
AB vs. DE: Other Considerations • Data Availability • Extra Levers in AB Models • Complexity vs. Analyzability • Simulation Cost • Limits to Understanding • Purpose of Modeling and Cost of Error • More Feedback vs. Disaggregation
Conclusions: Upsides of AB vs. DE • AB models offer additional insights when: • Sparse and locally connected networks • Capture “Non/low Diffusion” modes of behavior (important when low “contact number” (c*i*d) for epidemic) • Better tackle questions about effect of individual differences on overall behavior • Possibility of misleading parameter values in fitting curves to DE models
Conclusions: Downsides of AB vs. DE • Data are rarely available to the detail needed for an AB model • Marginal precision improvement on complexity is usually low, expanding the boundaries may pay back better. • Analysis is very hard: • Structure-behavior connection hard to explain • Simulation cost can get prohibitive fast • Hard to make sense of so much data
Process Insights • It is possible to build agent based models keeping up with good SD practice guidelines • Dimensional consistency • Independence from DT • Vensim software needs improvement to be used for AB models • Dealing with stochastic elements is not trivial!
Agenda • AB and DE Models • SEIR Model: DE and AB • Study Design: • Networks, Heterogeneity, and Calibration • Results • Overview, Three Metrics • Other Considerations • Conclusions and Lessons
Policy recommendations might be affected by model type. • Example: Reducing risk of smallpox bioterror attack: What is the right vaccination strategy? • Kaplan, Craft & Wein (2002) use a differential equation model; conclude Mass Vaccination is superior • Halloran et al. (2002) use agent model, conclude Targeted Vaccination is superior • What accounts for difference? AB vs. DE method, or other assumptions?
Single stock Disaggregated by age Disaggregated by region, age Disaggregated by country, age, gender, etc. … Each person represented People disaggregated into organs Organs disaggregated into cells … Atoms Quarks Highly aggregated Highly disaggregated AB vs. DE: A continuum, not an oppositionExample: modeling world population Typical DE models Typical AB model Agent model still aggregates lower- level entities
Goals • What are the differences between AB and DE methods? When might it matter? • Modeling discipline: Learning across boundaries • Challenges of crossing the boundary • Learning opportunities for both communities • Example: The diffusion of an epidemic • AB: Value added under what conditions? • DE: What might it miss?
Nonlinear differential equation paradigm: dx/dt = f(x,u) x vector of states; u, vector of exogenous inputs, including stochastic shocks; f() typically nonlinear Typically in continuous time but difference equations also common Finite number of compartments (elements of x) No heterogeneity within a compartment. Heterogeneity added by enlarging number of compartments, e.g.: Disaggregation by spatial structure: World population P becomes population by country Pi Disaggregation by attribute People P become Pijk…, where, e.g., i, j, k = sex, age, health status, behavior, etc.).
Example: SEIR Epidemic Model • 4 compartments (S, E, I, R) • Perfect mixing within compartments • No heterogeneity in infectivity (within E, I) or in network structure of social contacts
Agent-based paradigm: • Set A = {a1, … an} of agents, each agent has states xa • x can be e.g. health status, location, wealth, beliefs, decision rules, etc. • States xa change according to rules of interaction, e.g., • Nearest neighbor (on lattice, torus, etc.) or other network structure; • Stochastic or deterministic. • Discrete time: xa(t) = Rule[xa(t-1)] for all a in {A}] • Heterogeneity across agents. Often, distribution of states across agents (often assigned randomly) • Aggregation: • Population is sum of agents; Number of people in each category (e.g., health status, gender) is sum of agents with those attributes each period.
Each person in one of 4 states (S, E, I, R) • Each person interacts (deterministically or stochastically) according to a specified network structure of social contacts (e.g., some people highly, others weakly, connected) • Probability of infection given contact can differ for each person (heterogeneous attributes of each agent) • Discrete time Example: Agent-Based Epidemic Model • Example Decision Rules: • If S, then become E if any of your contacts this period are in E or I state and if those contacts result in infection • If E, then become I e days after exposure
Probability of Recovery= 1-(1-1/d)^One Day/TIME STEP • Symptomatic(t)=E( ) • Learning Lessons: Unit Consistency and Independence from TIME STEP Crossing Boundaries: A Simple Model DE Model • Recovery= S/d