Presentation on theme: "Continuous-time microsimulation in longitudinal analysis Frans Willekens Netherlands Interdisciplinary Demographic Institute (NIDI) ESF-QMSS2 Summer School."— Presentation transcript:
Continuous-time microsimulation in longitudinal analysis Frans Willekens Netherlands Interdisciplinary Demographic Institute (NIDI) ESF-QMSS2 Summer School Projection methods for ethnicity and immigration status, Leeds, 2 – 9 July 2009
What is microsimulation? A sample of a virtual population Real population vs virtual population –Virtual population is generated by a mathematical model –If model is realistic: virtual population real population Population dynamics –Model describes dynamics of a virtual (model) population Macrosimulation: dynamics at population level Microsimulation: dynamics at individual level (attributes and events – transitions)
Discrete-event simulation What is it?:the operation of a system is represented as a chronological sequence of events. Each event occurs at an instant in time and marks a change of state in the system. (Wikipedia) Key concept: event queue: The set of pending events organized as a priority queue, sorted by event time.
Types of observation Prospective observation of a real population: longitudinal observation –In discrete time: panel study –In continuous time: follow-up study (event recorded at time occurrence) Random sample (survey vs census) –Cross-sectional –Longitudinal: individual life histories
Longitudinal data sequences of events sequences of states (lifepaths, trajectories, pathways) Transition data: transition models or multistate survival analysis or multistate event history analysis –Discrete time: Transition probabilities Probability models (e.g. logistic regression Transition accounts –Continuous time Transition rates Rate models (e.g. exponential model; Gompertz model; Cox model) Movement accounts Sequence analysis: Abbott: represent trajectory as a character string and compare sequences
Why continuous time? When exact dates are important Some events trigger other events. Dates are important to determine causal links. Duration analysis: duration measured precisely or approximately –Birth intervals –Employment and unemployment spells –Poverty spells –Duration of recovery in studies of health intervention To resolve problem of interval censoring –Time to the event of interest is often not known exactly but is only known to have occurred within a defined interval.
What is continuous time? Precise date (month, day, second) –Month is often adequate approximation => discrete time converges to continuous time Transition models: dependent variable –Probability of event (in time interval): transition probabilities –Time to event (waiting time): transition rates
Time to event (waiting time) models in microsimulation Examples of simulation models with events in continuous time (time to event) –Socsim (Berkeley) –Lifepaths (Statistics Canada) –Pensim ((US Dept. of Labor) Choice of continuous time is desirable from a theoretical point of view. (Zaidi and Rake, 2001)
Time to event (waiting time) models in microsimulation Exponential model: (piecewise) constant transition (hazard) rate Gompertz model: transition rate changes exponentially with duration Weibull model: power function of duration Cox semiparametric model Specialized models, e.g. Coale-McNeil model Time to event is generated by transition rate model
Time to event is generated by transition rate model How? Inverse distribution function or Quantile function
Quantile functions Exponential distribution (constant hazard rate) –Distribution function –Quantile function Cox model –Distribution function –Quantile function Parameterize baseline hazard
Two- or three-stage method Stage 1: draw a random number (probability) from a uniform distribution Stage 2: determine the waiting time from the probability using the quantile function Stage 3: –in case of multiple (competing) events: event with lowest waiting time wins –in case of competing risks (same event, multiple destinations): draw a random number from a uniform distribution
Illustration If the transition rate is 0.2, what is the median waiting time to the event? The expected waiting time is
Illustration Exponential model with =0.2 and 1,000 draws
Table 1 Number of occurrences, given =0.2 Random samples of 1000 transitions Number of subjects by number of occurrences within a year Random sample 1 Random sample 2 Random sample 3 Expected values 0 829 797 828 819 1 152 189 153 164 2 18 12 17 16 3 1 2 2 1 4 0 0 0 0 5 0 0 0 0 Total 1000 Total number of occurrences within a year 191 219 193 200
Table 1 Times to transition Random samples of 1000 transitions and expected values Number of subjects by number of occurrences within a year Random sample 1 Random sample 2 Random sample 3 Expected values 10.5040.4780.483 20.6720.7050.700 30.9600.7400.596 4--- 5---
Multiple origins and multiple destinations State probabilities
Lifepaths during 10-year period Sample of 1,000 subject; =0.2 PathwayNumber NameMean age at transition 1325HD4.24D 2217H 3161H+4.03+ 4150HD+2.68D5.67+ 584HDH3.32D6.79H 640HDHD2.36D4.88H7.25D 711HDH+1.96D4.15H5.77+ 87HDHDH1.49D2.85H5.74D7.67H 93HDHD+1.64D3.86H4.97D6.78+ 102HDHDHD3.38D3.92H6.50D8.04H8.17D
Conclusion Microsimulation in continuous time made simple by methods of survival analysis / event history analysis. The main tool is the inverse distribution function or quantile function. Duration and transition analysis in virtual populations not different from that in real populations
Your consent to our cookies if you continue to use this website.