Clinicians increasingly want a survival model to answer one plain question about a patient: out of the next five years, how much time will this person live, or live event-free? That quantity is the restricted mean survival time (RMST). It is the area under the patient's survival curve up to a chosen horizon $\tau$, and it stays meaningful when the usual hazard-ratio summary breaks down, for example when treatment curves cross or diverge only late. Machine-learning survival models are rarely built or judged on this quantity. They are tuned for ranking accuracy (the concordance index), and when they do output a full survival curve, the area under it has to be computed numerically. This note proposes a survival network whose output distribution is a mixture of Erlang distributions (Gamma distributions with integer shape). With this choice, each patient's RMST at every horizon, the residual mean after a delay, and their gradients are finite sums of exponentials times polynomials. That makes it cheap to train directly against a censoring-aware RMST loss that is spread across many horizons at once.
The idea borrows a habit from wireless engineering, where performance integrals over complicated fading distributions are routinely analytically intractable. Engineers there replace the distribution with a Gamma mixture whose partial moments are known in closed form, and they read off the leading asymptotic term to summarize behavior in a regime that data cannot probe well. We apply both moves to survival data. The paper's claim is not that a closed form beats numerical integration on accuracy; for a one-dimensional integral it usually will not. The claim is that the Erlang family, together with an RMST-targeted loss, produces better-calibrated individual RMST curves across horizons, particularly near the end of follow-up and under heavy tails, than likelihood-trained Gaussian-mixture or binned models. As a side benefit, the model's implicit extrapolation assumption is exposed as two readable numbers.
Core Claim
For a component with integer shape $a$ and rate $b$, the restricted mean has the exact form
$$\mathbb{E}[\min(T,\tau)] = \frac{a}{b}\,P(a+1, b\tau) + \tau\,\bigl(1 - P(a, b\tau)\bigr),$$
where $P(a,x) = 1 - e^{-x}\sum_{j=0}^{a-1} x^j/j!$ is the regularized lower incomplete gamma function. For integer $a$ this is elementary. A patient-specific mixture with weights $\pi_k(x)$ and rates $b_k(x)$ output by a network, over a fixed grid of shapes $a_k$, gives $\text{RMST}(\tau\mid x)$ as a weighted sum of these terms. The restricted mean residual lifetime after a delay $a_0$ is $(\text{RMST}(\tau\mid x)-\text{RMST}(a_0\mid x))/S(a_0\mid x)$, which is also exact.
Two structural facts follow at no cost. First, the predicted RMST curve is automatically increasing and concave in $\tau$, because its derivative is $S(\tau\mid x)$. Second, the far tail is dominated by the component with the smallest rate, so $S(t\mid x)\sim c\,t^{a^\ast-1}e^{-b^\ast t}$. The pair $(b^\ast, a^\ast)$ summarizes what the model assumes beyond follow-up. It plays the same role for survival tails that the diversity and coding gains play in the high-SNR analysis of Parente et al., who show that a single leading term captures an intractable fading metric in its limiting regime.
The testable claim is this: when individual RMST is the target, the output family and the training loss matter more than whether the integral is closed-form. Specifically, Erlang mixtures trained with a horizon-integrated RMST loss will reduce censoring-weighted RMST error and RMST miscalibration relative to softplus-Gaussian mixtures and binned models. The gains should be largest for $\tau$ near maximal follow-up and under heavy-tailed data-generating processes.
Relation to Prior Work
Survival Mixture Density Networks motivate and constrain this work most directly. They output Gaussian mixtures pushed through a softplus so that $S(t)$ has an error-function closed form, and they report roughly a 100x training speedup over ODE-based SODEN (0.20 versus 23.82 seconds per METABRIC epoch). They do not compute RMST, which under their transform has no known closed form. The research file also notes that their Gaussian base family can mismatch heavy tails. We keep their mixture-output design but change the component family to one with native positive support and exact partial moments, and we change the training target. Learning Survival Distribution with Implicit Survival Function represents the alternative route: an arbitrary neural hazard integrated by Simpson's rule, evaluated by concordance. DeepHit takes the binned route. Both supply baselines, not method.
The method comes from wireless analysis. Enhancing Non-Terrestrial Network Performance with Free Space Optical Links and Intelligent Reflecting Surfaces and Performance Analysis of Outdoor THz Links under Mixture Gamma Fading with Misalignment use Mixture Gamma surrogates to make intractable outage and capacity integrals closed-form. STAR-RIS Aided NOMA in Multicell Networks uses moment-matched Gammas for cascaded channels. Those works fit a fixed surrogate to one known distribution, often by expectation-maximization, which the file flags as prone to local optima. We instead amortize the surrogate over covariates with a network and fix the shapes to an integer grid, which removes the unstable shape estimation entirely.
On the evaluation side, Position: Stop Chasing the C-index supplies the motivation: it finds that about 72% of surveyed 2023–2025 survival papers misalign metric and objective. We therefore make RMST error and RMST calibration primary and report concordance only as secondary. On the statistics side, Bayesian analysis of RMST adjusted for covariates using pseudo-observations regresses RMST at a single fixed $\tau$ via pseudo-observations. It is the strongest direct competitor at any one horizon, but it does not give a coherent curve across horizons. On Estimating Optimal Regime for Treatment Initiation Time Based on RMRL optimizes residual lifetime over a delay grid with kernel smoothing. Our exact RMRL makes that delay continuous, which we treat as a downstream demonstration rather than a core claim.
Research Program
The model is a feed-forward encoder that maps covariates to mixture weights and positive rates over a fixed shape grid, for example $a\in\{1,2,4,8,16,32\}$. Because Erlang mixtures with enough components can approximate any positive distribution, the grid trades flexibility for stability. We will ablate its size.
Training combines the censored log-likelihood, which is exact because density and survival are elementary, with an RMST loss. For each horizon drawn from a clinically motivated range, the RMST loss penalizes the gap between $\text{RMST}(\tau\mid x)$ and $\min(T,\tau)$, weighting observed cases by the inverse probability of remaining uncensored. Under independent censoring, this weighted squared error is minimized by the true conditional restricted mean, so the loss targets the right quantity. The censoring model is fit on a separate fold.
The analysis half does two things. It derives the tail pair $(b^\ast,a^\ast)$ per patient and uses it to produce an explicit, auditable extrapolation beyond follow-up, reported alongside a range of alternatives rather than as a single answer. It also characterizes the family: we will measure how many components are needed to reach a given RMST error for log-normal, Weibull, and heavy-tailed truths. This is the survival analogue of the mixture-order question in the wireless papers.
Baselines
The naive reference is covariate-free Kaplan–Meier RMST: the area under the pooled curve up to $\tau$, assigned to every patient. Any model that cannot beat it on censoring-weighted RMST error has learned nothing usable about individuals.
The strongest existing competitor for our actual question is Survival MDN with RMST computed by high-order Gauss–Legendre quadrature. It is continuous-time, free of the proportional-hazards assumption, and fast, and quadrature removes its only missing piece. We will train it with the same encoder width, the same hyperparameter search budget (equal numbers of trials, same validation folds), and both its original likelihood loss and our RMST loss. That makes it simultaneously the strongest baseline and the ablation that isolates the component family. A second ablation runs our Erlang model with likelihood only, isolating the loss.
The strongest single-horizon statistical competitor is pseudo-observation regression of RMST at each $\tau$, following the approach of Bayesian analysis of RMST adjusted for covariates using pseudo-observations. We will run it with a flexible regression on the same covariates, fit separately at every evaluation horizon.
We also include DeepHit, with RMST taken as the area under its step curve, and DeepSurv with a Breslow baseline, because DeepSurv is the familiar proportional-hazards deep model. For DeepSurv, the cited paper reports a METABRIC concordance of 0.867 against 0.816 for the Cox model (DeepSurv). We will reproduce concordance for comparability, but it is not our success criterion. We found no reported RMST-error or RMST-calibration result on Lacuna for any of these models on METABRIC, SUPPORT, GBSG, or MIMIC, so all headline numbers will be produced here under one protocol.
Beating a baseline means lower censoring-weighted RMST error and lower decile RMST miscalibration, averaged over five seeds and folds with non-overlapping paired-bootstrap intervals, at the late horizons in particular.
Why not just…?
Why not just integrate Survival MDN numerically? This is the real threat. For point accuracy at a moderate horizon, we expect quadrature on a well-trained Gaussian mixture to match any closed form. The closed form on its own is therefore not the contribution. The experiment separates the three candidate sources of benefit by crossing family (Erlang versus softplus-Gaussian) with loss (likelihood versus RMST) while holding integration exact in both arms. If the Gaussian arm with the RMST loss matches our model everywhere, including the late-horizon and heavy-tail simulations, we will report that the gain comes from the loss and that the family is unnecessary.
Why not just regress RMST directly with pseudo-observations at the horizon of interest? At a single prespecified $\tau$ this may be as good as or better than our model, and the Getug-AFU 15 analysis in that paper shows it works clinically. It does not give a patient a curve across horizons, and separate fits can produce RMST that decreases in $\tau$ or grows faster than $\tau$. Our experiments count how often such incoherence occurs and measure RMST error when the evaluation horizon differs from the fitted one. The file also notes that this approach becomes conservative at small sample sizes (around $n=50$), which our subsampling experiment probes.
Why not just use binned models such as DeepHit? Area under a step curve is easy to compute. But bin placement fixes resolution, and mass beyond the last bin is arbitrary. Both Survival MDN and ISF report precision loss from discretization. We test this directly by varying the bin count and measuring late-horizon RMST error.
Why not just fit a Cox model and integrate? RMST is used precisely because proportional hazards fails under crossing or delayed effects (Zhang et al.; Hua et al.). Our simulations include those regimes, where a proportional-hazards model should misstate individual RMST even when its ranking looks acceptable.
Proposed Experiments
The decisive experiment is simulation with known truth. We generate covariate-dependent survival from log-normal, Weibull with shape below one, and heavier-tailed mixtures, including crossing and delayed-effect treatment arms, with administrative and random censoring. We then compute true $\text{RMST}(\tau\mid x)$ on a horizon grid running up to the 95th percentile of follow-up. The primary outcome is RMST error against truth, broken down by horizon and tail type, across the family-by-loss factorial described above. The hypothesis fails if the Erlang advantage does not appear specifically at late horizons and heavy tails.
On real data we use METABRIC, SUPPORT, GBSG/Rotterdam, and MIMIC, with the splits and preprocessing of Survival MDN. This includes the Rotterdam-to-GBSG cross-study transfer from Deep Kernel Survival Analysis, which tests calibration under distribution shift. The metrics are censoring-weighted RMST error at several horizons; decile calibration, which compares mean predicted RMST in each decile to the Kaplan–Meier RMST of that decile; the rate of horizon-coherence violations; integrated Brier score; concordance; and wall-clock time per epoch. MIMIC's 82% censoring rate stresses the late-horizon regime.
A secondary check uses the hormonal-therapy indicator in GBSG. The population $\Delta\text{RMST}$ implied by averaging each model's individual predictions should agree with a doubly robust estimate in the spirit of Doubly Protected Estimation. Disagreement would indicate that good individual accuracy does not carry over to treatment contrasts.
Finally, as a demonstration of exact residual-lifetime evaluation, we optimize a continuous treatment-initiation delay on simulated data following the design of Chen et al.. We compare the fraction of individuals who do better than under standard regimes against their kernel estimator, which the paper reports at 78.5% to 89.6% in its simulations. We will match their simulation design as closely as its description allows.
References
- Asymptotic System Performance over Generalized Fading Channels with Application to Maximal-Ratio Combining
- Survival Mixture Density Networks
- Learning Survival Distribution with Implicit Survival Function
- DeepHit: A Deep Learning Approach to Survival Analysis With Competing Risks
- Enhancing Non-Terrestrial Network Performance With Free Space Optical Links and Intelligent Reflecting Surfaces
- Performance Analysis of Outdoor THz Links Under Mixture Gamma Fading With Misalignment
- STAR-RIS Aided NOMA in Multicell Networks: A General Analytical Framework With Gamma Distributed Channel Modeling
- Position: Stop Chasing the C-index when Evaluating Survival Analysis Models
- Bayesian analysis of restricted mean survival time adjusted for covariates using pseudo-observations
- On estimating optimal regime for treatment initiation time based on restricted mean residual lifetime
- DeepSurv: personalized treatment recommender system using a Cox proportional hazards deep neural network
- Statistical Issues and Lessons Learned From COVID-19 Clinical Trials With Lopinavir-Ritonavir and Remdesivir
- Biomarker-guided adaptive enrichment design with threshold detection for clinical trials with time-to-event outcome
- Deep Kernel Survival Analysis and Subject-Specific Survival Time Prediction Intervals
- Doubly Protected Estimation for Survival Outcomes Utilizing External Controls for Randomized Clinical Trials