🤖 AI Summary
Continuous-time survival models yield biased estimates when applied to discretized or interval-censored event times—common in clinical and administrative data—and fail to properly account for competing risks. Method: We propose the first Python-based, regularized (LASSO/elastic net) semiparametric discrete-time competing risks regression framework, built upon a discrete-time Cox-type formulation. It integrates synthetic data generation, model fitting, and comprehensive evaluation modules, enabling robust high-dimensional modeling and variable selection. Contribution/Results: Evaluated on MIMIC-IV clinical data, the method accurately predicts length of hospital stay. Monte Carlo simulations confirm unbiased parameter estimation and significantly superior predictive performance over mainstream continuous-time approaches—including the Fine–Gray model. This work fills a critical gap in the Python ecosystem for discrete competing risks modeling, combining theoretical rigor with practical scalability and reproducibility.
📝 Abstract
Time-to-event analysis (survival analysis) is used when the response of interest is the time until a pre-specified event occurs. Time-to-event data are sometimes discrete either because time itself is discrete or due to grouping of failure times into intervals or rounding off measurements. In addition, the failure of an individual could be one of several distinct failure types, known as competing risks (events). Most methods and software packages for survival regression analysis assume that time is measured on a continuous scale. It is well-known that naively applying standard continuous-time models with discrete-time data may result in biased estimators of the discrete-time models. The Python package PyDTS, for simulating, estimating and evaluating semi-parametric competing-risks models for discrete-time survival data, is introduced. The package implements a fast procedure that enables including regularized regression methods, such as LASSO and elastic net, among others. A simulation study showcases flexibility and accuracy of the package. The utility of the package is demonstrated by analysing the Medical Information Mart for Intensive Care (MIMIC) - IV dataset for prediction of hospitalization length of stay.