11.4. Discrete-Time Hazard and Competing-Risks Models
Methodological Part 11.4. Discrete-Time Hazard and Competing-Risks Models in 11. Survival, Event History and Competing-Risks Analysis provides step-by-step How-To implementation guides for 5 econometric model lessons spanning from Section 11.4.1 to 11.4.5. Full theoretical derivations are available at VietLOD Part 11.4 alongside cloud execution on EcoLab.
Video Tutorial: How-To Guide for Part 11.4: Discrete-Time Hazard and Competing-Risks Models in Stata 18, R 4.x, and Python 3.11+
11.4.1. Methodological Overview and Structural Equations
- Methodological Focus: Provides consistent estimation and robust inference for Discrete-Time Hazard and Competing-Risks Models specifications within Survival, Event History and Competing-Risks Analysis.
- Mandatory Post-Estimation Diagnostics: Tỷ số nguy cơ tương đương chính xác tham số Cox liên tục gốc, kiểm định LR dạng hàm nguy cơ cơ sở theo thời gian, deviance AIC/BIC..
Core structural specification for Part 11.4:
Estimator objective and moment conditions:
11.4.2. Econometric Model Lessons in Part 11.4
Exact discrete-time representation of an underlying continuous proportional hazards process on interval-grouped spells via person-period exp...
Directly estimates covariate effects on the Cumulative Incidence Function (CIF) via Inverse Probability of Censoring Weighted (IPCW) subdist...
11.4.3. Comparative Execution Syntax Across Stata 18, R 4.x, and Python 3.11+
| Section & Model Title | Estimator Key | Stata 18 MP Syntax | R 4.x Syntax | Python 3.11+ Syntax | Support |
|---|---|---|---|---|---|
| 11.4.1 · Prentice-Gloeckler Discrete-Time Complementary Log-Log Hazard | discrete_time_hazard | cloglog event_it x1 x2 i.spell_t, vce(cluster id) | glm(event_it ~ x1 + x2 + factor(spell_t), family = binomial(link = 'cloglog'), data = df) | smf.glm('event_it ~ x1 + x2 + C(spell_t)', data=df, family=sm.families.Binomial(sm.families.links.CLogLog())).fit() | Available |
| 11.4.2 · Fine and Gray Competing-Risks Subdistribution Hazard | fine_gray_competing_risks | stcrreg x1 x2, compete(event == 2) vce(robust) | cmprsk::crr(ftime = df$duration, fstatus = df$event, cov1 = df[, c('x1', 'x2')]) | CoxPHFitter().fit(df_ipcw, duration_col='duration', event_col='event_cr', weights_col='w_ipcw') | Available |
| 11.4.3 · Autoregressive Conditional Duration Model Engle Russell | acd_conditional_duration | streg x1 x2, distribution(weibull) time | ACDm::acdFit(model = 'ACD', dist = 'exponential') | AFT log-duration covariate adjustment + Bauwens-Giot Log-ACD(1,1) | Available |
| 11.4.4 · Shared Gamma Frailty Proportional Hazards and AFT Duration Model | shared_gamma_frailty_hazard | stset y & streg x1 x2, distribution(weibull) frailty(gamma) time | survival::survreg(Surv(y) ~ x1 + x2, dist = 'weibull') | Weibull-Gamma Frailty marginal Laplace-transform MLE + AFT log-duration elasticities | Available |
| 11.4.5 · Piecewise Constant Exponential Hazard Duration Model | piecewise_exponential_hazard | stset y & stsplit, at(failures) / streg x1 x2, distribution(exponential) time | eha::pchreg / stats::lm(log(y) ~ x1 + x2) | Holford-Laird-Olivier interval-exposure Poisson hazard + log-duration AFT projection | Available |
11.4.4. Standard Implementation Workflow for Part 11.4
Step 1. Load Standardized Practice Datasets From VietLOD, EcoData, or Finco
Download the model-specific .csv practice dataset in Part 11.4 or extract custom empirical panels from EcoData and Finco.
Step 2. Select the Optimal Estimator for Your Error and Sample Structure
Compare the estimators from 11.4.1 to 11.4.5 in the syntax matrix above and execute the estimation in Stata 18 MP, R 4.x, or Python 3.11+.
Step 3. Run Mandatory Diagnostics and Export Publication Tables on EcoLab
Verify all required diagnostics including Tỷ số nguy cơ tương đương chính xác tham số Cox liên tục gốc, kiểm định LR dạng hàm nguy cơ cơ sở theo thời gian, deviance AIC/BIC. and dispatch the specification to EcoLab for automated journal-grade reporting.