1 / 25

Data structure for a discrete-time event history analysis

Data structure for a discrete-time event history analysis. Jane E. Miller, PhD. Overview. Structure of most survey data: One record per respondent Discrete-time event history analysis requires separate records for each person-time unit at risk of the event

rkendrick
Download Presentation

Data structure for a discrete-time event history analysis

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Data structure for a discrete-time event history analysis Jane E. Miller, PhD

  2. Overview • Structure of most survey data: One record per respondent • Discrete-time event history analysis requires separate records for each person-time unit at risk of the event • Review: How to create one record per spell • How to create one record per person-time unit • Components of the dependent variable • Fixed characteristics • Time varying characteristics The Chicago Guide to Writing about Multivariate Analysis, 2nd Edition.

  3. Data preparation for an event history • Survey data often contains one record per respondent • Continuous-time event history data contain one record per spell • Discrete-time event history analysis requires one record per person-time unit within each spell • E.g., one record for each person-month at risk of divorce, within each spell at risk of divorce

  4. Source data from survey: 1 record per respondent

  5. Example timelines for study of divorce M = Married D = Divorced L = Lost to follow-up O = Censored by end of study. X = Died Case 1: Never married -> no spells Case 2: Married once, censored by end of survey O M Not married -> not at risk of divorce -> not part of a spell Case 3: Married twice, lost to follow-up before end of survey M D M L Case 4: Married once, died before end of survey X M End of observation period

  6. Continuous-time event history data • One record for each period at risk (spell) • Duration of overall spell • Event indicator at end of spell

  7. Event history timeline: Discrete time specification Four person-month units Case 2, Continuous time version: One four-month spell Married 6/22/2010 Last surveyed 11/5/2010 Case 2, Discrete-time version: Eachperson-month unit becomes one record -> unit of analysis. All records for each spell include respondent ID and other characteristics. 1st person-month Married O O = Censored 2nd person-month O O 3rd person-month O O 4th person-month O End of survey

  8. Discrete-time data set: ID codes on person-time records • Each person-month record carries the respondent ID • Each record within a given spell also includes the spell # for that respondent

  9. Record number within spell • Each month in a spell will generate one person-month record, e.g., • respondent #2 is observed for 4 months -> 4 person-month records • respondent #3 contributes a total of 84 records • 77 in his first spell • 7 in his second spell

  10. Month counter within spell The “month # within spell” counter indicates the start time of the person-month at risk for that record. E.g., the first record for a given spell starts at baseline (time point 0).

  11. Duration measure for each record within spell The duration measure will = 1 time units for all person-time records within a given spell EXCEPT = 0.5 for the last month in a spell

  12. Status indicator for each record within spell The indicator for status at end of record will = 0 for all person-time records within a given spell EXCEPT the last one because by definition they end in censoring (the spell is not yet complete)

  13. Status indicator for last record within spell The indicator for status at end of record for the lastperson-time record within each spell will take on the value of the status indicator for the overall spell

  14. Event indicator for each record within spell

  15. Fixed covariates for each person-time record Age, number of children at start of spell, and gender do not change during the course of a spell, so they have the same value for each person-time record within a given spell

  16. Example timelines for number of children as time-varying covariate in study of divorce Columns reordered into chronological order M C D M L Case 3: No kids One kid X M C C Case 4: No kids One kid Two kids M = Married D = Divorced C = Child born L = Lost to follow-up O = Censored by end of study. X = Died

  17. Discrete time with time-varying covariates • Case 3 has his first child 64 months into his first marriage, and no additional children while observed. # kids at start of record is • 0 for his first 63 records of spell 1 • 1 for records 64 through 77 of spell 1 • 1 for all records in spell 2

  18. Discrete time with time-varying covariates • Case 4 has her first child 15 months into her marriage, a second child in month 47 after marriage. For her the # kids at start of record is • 0 for her first 15 records • 1 for records 15 through 46 • 2 for records 47 or higher, all in spell 1

  19. Presenting information on event history construction: Background work • Most of the gory details of creating an event history are part of behind-the-scenes work • Important to do consistency checks to make sure event histories were created correctly given • Original data source of information for timeline construction • Type of event under study • Fixed covariates • Time-varying covariates • E.g., correct • Number of spells per respondent • Number of person-time records for each spell • Duration and event indicators for each person-time record • Values of fixed- and time-varying covariates for each person-time record

  20. Presenting information on event history construction • In the data and methods section, describe: • Original data source of information for timeline construction • Dates, status, duration of events • Type of event under study • Unit of person-time (e.g., person-years, person-months) • What constitutes censoring • Fixed covariates • Time-varying covariates • Source(s) of information for determining timing of changes in those variables • See checklist in chapter 17 of Writing about Multivariate Analysis, 2nd Edition for more detail on what to report

  21. Summary • A discrete-time event history analysis requires a separate record for each person-time unit at risk of the event • For each respondent, create correct number of spells • For each spell, calculate • Correct number of person-time units • Components of the dependent variable • Duration measure • Event indicator • Fixed characteristics • Time-varying characteristics • In data and methods section, describe data sources and variables for the event history The Chicago Guide to Writing about Multivariate Analysis, 2nd Edition.

  22. Suggested resources • Allison, P. D. 2010. Survival Analysis Using the SAS System: A Practical Guide, 2nd Edition. Cary, NC: SAS Institute. • Miller, J. E. 2013. The Chicago Guide to Writing about Multivariate Analysis, 2nd Edition. University of Chicago Press, chapter 17. The Chicago Guide to Writing about Multivariate Analysis, 2nd Edition.

  23. Suggested online resources • Podcast on data structure for a continuous-time event history analysis

  24. Suggested exercises • Study guide to The Chicago Guide to Writing about Multivariate Analysis, 2nd Edition. • Question #3a in the problem set for chapter 17 • Suggested course extensions for chapter 17 • “Reviewing” exercises #2a through 2h • “Applying statistics and writing” exercises #1 and 2a

  25. Contact information Jane E. Miller, PhD jmiller@ifh.rutgers.edu Online materials available at http://press.uchicago.edu/books/miller/multivariate/index.html The Chicago Guide to Writing about Multivariate Analysis, 2nd Edition.

More Related