Next Article in Journal
A Projection-Free Sparse Model Order Reduction Method for Thermomechanical Multibody Dynamics
Previous Article in Journal
Finite-Volume Stability and Flux Sectors in a Reciprocal Ratio Gradient Model on Graphs
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

A Temporal Convolutional Network Deep Cox Mixtures Model for Dynamic Risk Prediction

School of Economics, Jinan University, Guangzhou 510632, China
*
Author to whom correspondence should be addressed.
These authors contributed equally to this work.
Mathematics 2026, 14(15), 2727; https://doi.org/10.3390/math14152727
Submission received: 22 June 2026 / Revised: 21 July 2026 / Accepted: 25 July 2026 / Published: 1 August 2026
(This article belongs to the Section E: Applied Mathematics)

Abstract

Dynamic risk prediction is an important statistical technique for detecting temporal changes in risk and provides quantitative support for early risk identification in clinical decision-making, industrial process monitoring, and financial anomaly detection. This study proposes a Temporal Convolutional Network Deep Cox Mixtures Model (TCN-DCM) for longitudinal survival data by integrating a temporal convolutional network, which learns temporal patterns from longitudinal covariates, with a Deep Cox Mixtures framework that relaxes the conventional proportional hazards assumption. Simulation studies were conducted to compare the proposed model with existing deep learning-based methods, including recurrent deep survival machines and Dynamic-DeepHit, as well as the traditional joint model. The results showed that, when the proportional hazards assumption held, TCN-DCM outperformed the existing deep learning-based models. When the proportional hazards assumption was violated, TCN-DCM achieved predictive performance comparable to that of recurrent deep survival machines and yielded superior results for some evaluation metrics. The proposed model was further applied to a primary biliary cholangitis dataset, where it achieved the best overall predictive performance and demonstrated individualized dynamic survival risk prediction. These findings indicate that TCN-DCM provides a flexible and broadly applicable approach for dynamic risk prediction in longitudinal survival analysis.

1. Introduction

Longitudinal data, which capture the dynamic temporal variation of covariates, serve as an indispensable data foundation for research on individual dynamic prediction [1]. As a critical statistical technique for risk identification in fields including clinical medicine and business administration, dynamic risk prediction provides reliable support for risk assessment and scientific decision-making regarding adverse outcomes such as disease progression, equipment failure, traffic accidents, special treatment (ST) of listed securities, and financial fraud [2,3].
Existing dynamic risk prediction methods are mainly categorized into three paradigms: joint models (JMs), landmark models, and deep learning-based models. The joint model framework decomposes the data into a longitudinal process and a survival process [4]. Information extracted from the longitudinal process via panel data models is incorporated into the subsequent risk model. The most classical specification is the joint modeling of a linear mixed-effects model and the Cox proportional hazards model. The landmark model partitions the full follow-up period into segments at predefined landmark time points and constructs separate risk models for each segment [5]. This framework generates hazard rates at multiple future time points conditional on each landmark, thereby enabling dynamic prediction. For deep learning-based models, the typical architecture consists of two sub-networks designed for longitudinal feature learning and risk estimation, respectively [6]. Departing from the conventional form of statistical models, these data-driven models output dynamic hazard rates through a black-box neural network structure.
While extensions of JMs have been developed to address high-dimensional covariates and population heterogeneity [7,8], these methods generally retain the proportional hazards (PH) assumption. This strict assumption restricts their utility for dynamic risk prediction based on longitudinal data in scenarios where the PH assumption fails to hold. Rizopoulos et al. noted that while landmarking approaches are straightforward to implement, they suffer from inherent misspecification of time effects [9]. Landmark time points must be predefined prior to model application, and the appropriateness of these points depends on prior knowledge of the underlying mechanisms of risk occurrence, which in turn reduces the practical usability of landmark models. More recently, Rizopoulos and Taylor used Super Learning to combine dynamic predictions from joint models with different longitudinal trajectories and association structures, thereby reducing dependence on a single model specification. However, this approach still requires the construction and repeated fitting of a library of candidate joint models and does not completely eliminate model-specification and computational concerns [10].
Among deep learning-based approaches, Dynamic-DeepHit uses an RNN and an attention mechanism to encode longitudinal measurement histories and applies feedforward networks to produce dynamic survival risks [6], whereas RDSM combines recurrent representation learning with fully parametric survival-time distributions [11,12]. More recently, tdCoxSNN incorporated neural networks into a time-dependent Cox model to capture nonlinear effects of time-varying covariates on a continuous-time scale [13], while DySurv used conditional variational inference to jointly process static and longitudinal electronic health-record data [14]. Although these methods improve the ability to learn complex temporal patterns, they do not simultaneously combine longitudinal sequence representation, latent risk heterogeneity, and a within-component Cox structure, and the statistical interpretation of their deep representations remains limited.
Nagpal et al. proposed Deep Cox Mixtures (DCM), which represents individual survival distributions using a finite mixture of Cox models and estimates component-specific relative risks together with nonparametric baseline hazards [15]. This framework can represent population risk heterogeneity and relax the global PH assumption. However, the original DCM primarily relies on static covariate representations and does not include a temporal architecture for extracting ordered information from repeated longitudinal measurements. It therefore cannot directly update its longitudinal representation when new follow-up information becomes available.
Taken together, three issues have not been addressed simultaneously in the existing literature: joint models may be sensitive to the specification of the longitudinal process and association structure; longitudinal deep survival models generally lack an explicit latent Cox mixture structure; and the original DCM does not fully exploit the temporal ordering of longitudinal observations. To address these gaps, we integrate a causal dilated temporal convolutional network with DCM. The TCN extracts a representation of the longitudinal history available up to the current visit, which is then used to estimate both the latent-component probabilities and the component-specific risks. This enables dynamic updating of individualized survival probabilities while retaining a Cox structure within each latent component. We further evaluate the roles of the model components through unified data partitions, parameter sensitivity analyses, and internal ablation experiments.

2. Model

2.1. Individual-Level Data

A longitudinal dataset containing survival information is formally defined as
D = X i , j , δ i , j , t i j = 1 J i i = 1 N ,
where X i , j represents the covariate vector of individual i at the j-th time point, J i denotes the number of follow-up observations for individual i, and N is the total number of individuals; δ i , j indicates the status of individual i at the j-th time point, taking values that indicate either event occurrence or censoring; and t i denotes the survival time or censoring time as indicated by δ i , j .

2.2. Temporal Convolutional Network

A temporal convolutional network f : X T Y T is established on the covariates of each individual, such that y t is determined by x 0 , , x t . The network f minimizes the expected loss between the actual outputs and the predictions:
L y 0 , , y T , f ( x 0 , , x T ) .
Here, x 0 , , x T denote the longitudinal covariate inputs arranged according to observation time, and y 0 , , y T denote the corresponding outputs learned by the temporal convolutional network.
As illustrated in Figure 1, to handle partially missing values in longitudinal data, this study constructs a corresponding binary missing-value mask for each longitudinal covariate. For observed values, standardization is first performed using parameters estimated from the training fold. For missing values, their standardized numerical channels are set to 0, and the corresponding masks are set to 1. The inputs to the TCN consist of longitudinal features and the corresponding missing-value masks. The TCN first extracts local features from the temporal patterns of the data using dilated causal convolution blocks (labeled as “Convolution” blocks in Figure 1) to learn the underlying patterns of longitudinal covariates. Residual blocks are incorporated to refine the feature mapping, thereby mitigating the vanishing and exploding gradient problems in deep networks and improving computational efficiency, ultimately yielding learned covariate representations. Rectified linear unit (ReLU) functions are applied as nonlinear activation functions after each network layer to further alleviate the vanishing gradient issue. Dropout layers are adopted to randomly deactivate a proportion of neural units during training with a predefined probability, thereby reducing model overfitting. For individual i, the original covariate vector x i j observed at the j-th follow-up time point is transformed by the temporal convolutional network into the learned covariate representation y i j . This representation encodes all longitudinal covariate information observed for individual i up to and including time t i .

2.3. Deep Cox Mixtures Model

As shown in Figure 1, the Deep Cox Mixtures model assumes that each individual’s survival distribution can be represented as a finite mixture of K Cox models, where K is the number of latent Cox components. The mixture weight of the k-th latent component is determined from the individual’s covariates through the gating function g ( · ) . When K = 1 , the latent-component probability is identically one, the latent Cox mixture structure disappears, and the model reduces to a single TCN-Cox model. The procedure used to select the number of latent Cox components is described in Section 2.5.1.
The full likelihood function of the Deep Cox Mixtures model is formulated as follows:
L θ , { Λ k } k = 1 K = i = 1 | D | j = 1 J i k = 1 K λ k t i y i j δ i S k t i y i j P Z = k y i j .
Here, θ denotes the collection of neural network parameters, and Λ k denotes the baseline cumulative hazard function for the k-th latent Cox cluster, which is estimated using the Breslow estimator as follows:
Λ ^ k ( t ) = i : t i < t 1 j R k ( t i ) exp f k ( θ ^ f , y j ) ,
where the risk set R k ( t i ) is a set of individuals in the k-th latent cluster that survived beyond time t i . For the k-th latent cluster, the hazard function is
λ k t i | y i j = λ k t i exp f k θ f , y i j ,
where λ k t i denotes the baseline hazard function of the k-th latent Cox cluster, and f k θ f , y i j denotes the cluster-specific log-hazard function. The corresponding survival function is
S k t i | y i j = exp { 0 t i λ k ( s ) exp ( f k ( θ f , y i j ) ) d s } = S k t i exp f k θ f , y i j ,
where S k t i denotes the baseline survival function of the k-th latent Cox cluster. The mixture weight is given by
P Z = k y i j = softmax k g θ g , y i j .
Here, g θ g , y i j is the output of the gating function, and softmax k ( · ) denotes the k-th element of the softmax output. Specifically, let a i j = g θ ( h i j ) = a i j 1 , , a i j K be the K-dimensional vector of gating logits computed from the TCN representation h i j . Through the softmax function, the mixture weight of the k-th latent Cox component is defined as
π i j k = softmax k ( a i j ) = exp ( a i j k ) = 1 K exp ( a i j ) , k = 1 , , K .
Consequently, for every individual i and follow-up time t i j , the mixture weights satisfy π i j k > 0 and k = 1 K π i j k = 1 . The quantity π i j k can therefore be interpreted as the model-estimated probability that the observation at t i j belongs to the k-th latent Cox component.
The gating function g ( · ) and the linear function f ( · ) are implemented using fully connected layers. They take the learned covariate representations to estimate the cluster-specific log-hazard function f k θ f , y i j within each Cox model and the mixture weights P Z = k | y i j , respectively.
The identifiability of TCN-DCM is primarily affected by label switching in the mixture model and by non-unique neural-network parameterizations. Arbitrarily permuting the latent-component labels together with the corresponding gating probabilities, component-specific risk functions, and baseline survival functions leaves the overall mixture survival distribution unchanged; therefore, the numerical labels of the latent components have no fixed intrinsic meaning. In addition, different parameterizations of the TCN, gating network, and component-specific risk network may represent the same or approximately the same input-output function, so individual neural-network weights are not strictly uniquely identifiable. Practical weak identifiability may also arise when two latent components learn highly similar risk structures.
Accordingly, we do not claim strict global identifiability of every network parameter; instead, we focus on the stability of the overall survival distribution, individualized predictions, and latent risk structure.

2.4. Expectation–Maximization Algorithm

To solve the full likelihood function of the proposed model, two sets of covariate-dependent unknown parameters need to be estimated. The cluster-specific log-risk function f k θ f , y i j and the gating function g k θ g , y i j are expressed as
f k θ f , y i j = θ f 1 y i j 1 + θ f 2 y i j 2 + + θ f m y i j m ,
g k θ g , y i j = θ g 1 y i j 1 + θ g 2 y i j 2 + + θ g m y i j m .
Here, y i j m denotes the m-th element of the learned covariate representation y i j .
Due to the large number of parameters to be estimated, it is intractable to obtain the optimal solution directly by maximizing the likelihood function. Therefore, this paper incorporates the initial values of f k θ f , y i j and g k θ g , y i j derived from the temporal convolutional network in Section 2.2 into the expectation–maximization (EM) algorithm for parameter estimation [16]. For notational simplicity, y i denotes the learned covariate representations used for individual i.
The approximate Monte Carlo expectation–maximization (MCEM) algorithm for the Deep Cox Mixtures model is described below [17].

2.4.1. E-Step

In this step, we calculate the posterior probability γ i of each individual belonging to the k-th latent cluster.
Since
γ i = P ( Z | T , Y ) P ( T | Z , Y ) = P ( T = t | Y , Z ) δ i P ( T > t | Y , Z ) 1 δ i ,
based on the expressions for the hazard function
λ k t | y i = λ k t exp f k θ f , y i ,
and the survival probability function
S k ( t | y i ) = S k ( t ) exp ( f k ( θ f , y i ) ) ,
we derive the event probability estimates as follows:
P ^ T > t Y = y i , Z = k = S ^ k ( t ) exp { f k ( θ ^ f , y i ) } ,
P ^ T = t Y = y i , Z = k = exp { f k ( θ ^ f , y i ) } S ^ k ( t ) exp { f k ( θ ^ f , y i ) } S ^ k ( t ) t S ^ k ( t ) .
Here, the baseline survival function S ^ k ( t ) is estimated using polynomial spline interpolation.

2.4.2. M-Step

The objective function is defined as
Q ( θ ) = i = 1 | D | k = 1 K γ i k log P ( Z = k Y = y i ) + ζ i k log P ( T = t i Z = k , Y = y i ) .
Here, γ i [ 0 , 1 ] is the posterior probability obtained from the E-step.
Since γ i P ( T i | Z i = k , Y = y i ) , we use ζ i Categorical γ i as a substitute during parameter inference.
The estimator of Q ( θ ) is given by
Q ^ ( θ ) = i = 1 | D b | k = 1 K γ i k log softmax k g ( θ g , y i ) + k = 1 K log PL D b k , θ .
Here, D b denotes the b-th mini-batch of longitudinal data, and D b k represents the subset of longitudinal data belonging to the k-th latent cluster within the b-th mini-batch. P L D b k , θ is the partial likelihood function based on the Cox model for the k-th latent cluster. The notation softmax k ( · ) denotes the k-th element of the softmax output, corresponding to the estimated mixture weight of the k-th latent cluster.
The MCEM algorithm does not directly estimate or impute missing longitudinal covariates. It is used only to handle the unobserved latent Cox components and, based on the longitudinal representation, to compute posterior responsibilities and update the model parameters. Specifically, let M denote the number of Monte Carlo latent-component allocations used in each parameter update. According to the posterior responsibilities obtained in the E-step, M sets of component labels are sampled independently, and the corresponding within-component Cox losses are averaged; the gating loss is calculated directly from the posterior responsibilities. When M > 1 , the Breslow baseline survival estimates obtained from the multiple allocations are averaged on a common time grid.
To assess whether generative representation regularization improves longitudinal survival prediction, we additionally considered an optional variational autoencoder (VAE) auxiliary branch during model development.
For individual i at observation time j, the TCN representation h ij is processed by the VAE encoder to produce a mean vector μ ij and a log-variance vector log σ ij 2 for the latent-variable distribution. During training, the latent variable is obtained by the reparameterization trick as
z ij = μ ij + σ ij ε ij , ε ij N ( 0 , I ) ,
L VAE = L rec + L KL ,
L ( Θ ; α ) = L Cox + L gate + α L VAE .
Meanwhile, considering both Q ^ θ , D b and the information loss induced by variational autoencoder (VAE) encoding, the loss function is formulated as
Loss θ , D b = Q ^ θ , D b + α Loss VAE θ , D b .
Here, Loss VAE = L VAE , and the latent representation is sampled from a Gaussian prior with zero mean and identity covariance matrix [18].
After each epoch, the average negative approximate Q-function was evaluated on the validation set. Training was terminated when either the prespecified maximum number of epochs was reached or the validation loss increased relative to the preceding epoch for three consecutive epochs. The total training and validation losses, component-wise Cox and gating losses, and computation time were recorded at every epoch for numerical convergence diagnostics.
By minimizing the loss function, we update the parameter set θ and the baseline survival function S ^ k ( t ) for each latent cluster. The estimated survival probability of an individual at time t is calculated as
P ^ T > t Y = y i = E Z P ^ ( Z Y ) P ^ T > t Y = y i , Z = k = 1 K S ^ k ( t ) exp { f k ( θ ^ f , y i ) } softmax k g ( θ ^ g , y i ) .
We did not calculate parameter-wise standard errors or an inverse Fisher information matrix for the high-dimensional parameters of the TCN, gating network, and component-specific risk networks. Because the objective is non-convex, the mixture components are subject to label switching, and the optimization involves stochastic Monte Carlo component allocations, uncertainty approximations based on a local Hessian or observed information matrix may be numerically unstable and difficult to interpret for individual neural-network weights.

2.5. Model Specification and Sensitivity Analyses

To ensure comparability across model configurations, all parameter-selection, internal-ablation, and sensitivity analyses used the same patient-level cross-validation folds, input variables, within-fold preprocessing, initialization rules, training procedure, stopping criteria, and evaluation horizons. In each comparison, only the model component or parameter under investigation was changed, while all remaining settings were held fixed.
Candidate configurations were evaluated using the time-dependent concordance index C td , dynamic AUC, and Brier score, together with the composite metric
S c o r e = C td + A U C + ( 1 B S ) 3 .
Definitions of C td , AUC, and BS are provided in Section 3.2.
Higher values of C td and AUC and lower values of BS yield a higher Score. To avoid selecting an unnecessarily complex model because of a negligible numerical difference, we used a parsimony rule: if the Score of a structurally simpler candidate was within 0.005 of the highest Score, the simplest such candidate was selected; otherwise, the configuration with the highest Score was selected. Complete parameter-selection and ablation results are reported in Appendix A.

2.5.1. Selection of the Number of Latent Cox Components

The number of latent Cox components K determines the complexity with which the model represents individual-level risk heterogeneity. A smaller K gives a simpler structure but may not adequately characterize latent risk differences, whereas a larger K increases flexibility but may introduce redundant components and reduce the stability of estimation and component interpretation.
Accordingly, we systematically compared K { 1 , 2 , 3 , 4 , 5 , 6 } . During the comparison of K, the VAE weight, number of Monte Carlo draws, network architecture, number of training epochs, data-preprocessing procedure, random-initialization rule, and cross-validation folds were held fixed, so that differences across configurations primarily reflected the number of latent Cox components.

2.5.2. Selection of the VAE Weight and Number of Monte Carlo Draws

To evaluate the effect of VAE auxiliary regularization on dynamic survival prediction, we considered
α { 0 , 0.01 , 0.1 , 1 } ,
where α = 0 denotes the absence of the VAE reconstruction-loss and KL-divergence constraints, whereas the remaining values represent different strengths of auxiliary regularization. For each fixed number of Monte Carlo draws, α = 0 was compared with the positive VAE weights to determine whether the auxiliary task produced a stable predictive benefit. Allowing α = 0 to be selected avoided assuming in advance that VAE regularization must improve predictive performance.
Let M denote the number of Monte Carlo latent-component allocations used in each MCEM parameter update. We compared
M { 1 , 5 , 10 } .
For a fixed VAE weight, models with different M values were trained using identical data partitions, network architecture, and stopping criteria. This comparison assessed whether additional Monte Carlo draws reduced variation induced by stochastic component allocation and whether any predictive benefit justified the additional computational cost.
After determining K, the candidate combinations of α and M were compared systematically, and the configuration for each data setting was selected according to the composite Score and parsimony rule.

2.5.3. Internal Ablation and Optimization-Stability Analyses

To quantify the contribution of each TCN-DCM component, we conducted the following internal ablation and sensitivity analyses using both the simulated and PBC data.
First, to evaluate the contribution of the masked causal dilated TCN temporal-representation module, the TCN encoder was replaced by landmark-safe cumulative mean pooling to construct a Mean-pooling DCM. This model summarized only longitudinal information available at or before the current landmark time while retaining the missingness indicators, latent Cox mixture structure, and all remaining training settings.
Second, to evaluate the contribution of the Deep Cox latent-mixture structure, the number of latent Cox components was fixed at K = 1 , yielding a TCN-Cox model. This model retained the TCN temporal encoder but removed the multi-component mixture structure and latent-component assignment mechanism. Because K = 1 was also a candidate in the component-number sensitivity analysis, the same result was used to quantify the independent contribution of the mixture structure.
Third, at the same M, the contribution of the VAE component was evaluated by comparing α = 0 with the positive VAE weights. The MCEM estimation procedure cannot be removed while retaining the same latent-mixture likelihood; therefore, we compared different values of the number of Monte Carlo draws M and combined these comparisons with fold-level convergence diagnostics to evaluate the predictive and numerical stability of the MCEM implementation.
To evaluate the sensitivity of MCEM optimization to parameter initialization, four prespecified random seeds were examined. Because neural-network parameters admit hidden-unit permutations, rescaling, and other non-unique representations, individual network weights were not compared element by element across initializations. Instead, practical sensitivity was assessed using out-of-fold C td , AUC, BS, the composite Score, and the standard deviation of the Score. The model outputs did not exhibit strong practical sensitivity to the initialization schemes examined.
For each fold, we also recorded the best-validation epoch, stopping epoch, minimum validation loss, and validation loss at stopping, and calculated the proportion of valid training histories to assess the numerical convergence of MCEM optimization. Complete internal-ablation, parameter-sensitivity, random-initialization, and convergence-diagnostic results are provided in Table A1, Table A2, Table A3, Table A4, Table A5, Table A6, Table A7, Table A8, Table A9 and Table A10.
Code for simulation-data generation and the TCN-DCM model is provided in the Supplementary Materials.

3. Simulation Study

3.1. Simulation Scenarios

Data were generated using a JM. The longitudinal process with j time points was modeled using a linear mixed-effects model, which incorporates the main effects of 10 binary baseline covariates, as well as a random intercept and a random slope [19].
y i j ( t ) = m i j ( t ) + ε i j ( t ) = x i j β j + z i j b i j + ε i j ( t ) ,
where y i j ( t ) denotes one longitudinal measurement of individual i at time point t; x i j and z i j are covariate vectors associated with the fixed-effect vector β j and the random-effect vector b i j , respectively. The random-effect vector follows a zero-mean normal distribution b i j N 0 , G j , where G j is the variance-covariance matrix. The covariate vectors are independent of the random error ε i j ( t ) N 0 , σ j 2 . The observed estimate of each latent longitudinal covariate is m i j ( t ) , which includes
x i j = 1 , t , X i 1 , X i 2 , X i 3 ,
X i 1 , X i 2 , X i 3 Bernoulli ( p ) ,
z i j = 1 , t .
In Scenario (1), the simulated data followed a standard joint-model specification in which the event hazard depended on the current longitudinal value. Scenario (2) incorporated both a time-varying effect of the current longitudinal marker and a cumulative historical-average effect, causing the association between the longitudinal marker and event risk to change over time and thereby strengthening the violation of the global PH assumption.
Scenario (1):
h i ( t ) = h 0 ( t ) exp γ w i + α 1 m i j ( t ) .
Scenario (2):
h i ( t ) = h 0 ( t ) exp γ w i + α ( t ) m ˜ i ( t ) + η m ¯ i ( t ) ,
where
w i = X i 1 , X i 2 , X i 3 ,
w i is the vector of baseline covariates. α ( t ) = 0.50 t 15 , η = 0.40 ; m ˜ i ( t ) denotes the standardized current longitudinal marker, and m ¯ i ( t ) denotes its historical mean up to t. Let μ m and σ m be the mean and sample standard deviation, respectively, of all m i ( t g ) values. Then m ˜ i ( t g ) = m i ( t g ) μ m σ m . In addition, the standardized historical mean of the longitudinal marker up to time t is defined as m ¯ i ( t ) = 1 t 0 t m ˜ i ( s ) d s , t > 0 .
The baseline hazard followed a Weibull distribution, specified as
h 0 ( t ) = exp σ 1 σ 2 t σ 2 1 .
In addition, seven binary noise variables, X i 4 , X i 5 , , X i 10 , were simulated as irrelevant covariates in the longitudinal data.

3.2. Performance Evaluation Metrics

We used twice-repeated patient-level five-fold cross-validation. In each repetition, approximately 80% of patients were used for model training and the remaining 20% for out-of-fold evaluation; the two partitions were generated using different prespecified random seeds, and all competing models used the same patient-level fold assignments.
The prediction windows t were set to [ 2 , 3 , 4 , 5 ] , and the predictive performance of the model was evaluated using the time-dependent concordance index C td , area under the ROC curve (AUC), and Brier score (BS).
For C td , we used the censoring-adjusted estimator proposed by Gerds [20], which is constructed based on the Kaplan–Meier estimator of the inverse probability of censoring weights (IPCW):
C td ( t ) = P F ^ ( t x i ) > F ^ ( t x j ) δ i = 1 , T i < T j , T i t .
The AUC adjusts sensitivity using the IPCW-based estimate of the censoring distribution [21]:
Se ^ ( c , t ) = i = 1 n ω i I { π i ( t ) > c , T i t } i = 1 n ω i I { T i < t } ,
ω i = δ i n G ^ ( T i ) ,
Sp ^ ( c , t ) = i = 1 n I { π i ( t ) c , T i > t } i = 1 n I { T i > t } ,
where Se ^ ( c , t ) and Sp ^ ( c , t ) denote the estimated sensitivity and specificity at the classification threshold c and time point t, respectively. G ^ t is the Kaplan–Meier estimator of the censoring distribution, I · is the indicator function, and π i ( t ) represents the survival probability P T > t | X = x i estimated by the classifier.
The BS measures the mean squared error of binary predictions for event occurrence probabilities at the quantiles of event time. In general, a BS value of 0 indicates perfect prediction, while a BS value of 0.25 indicates performance no better than random guessing. A smaller BS value corresponds to more accurate prediction performance.
BS ^ IPCW ( t ) = 1 n i = 1 n π i ( t ) 2 I { T i t , δ i = 1 } G ^ ( T i ) + { 1 π i ( t ) } 2 I { T i > t } G ^ ( t ) .

3.3. Analysis of Simulation Results

According to the selection rules specified in Section 2.5.1 and Section 2.5.2, the final simulation analyses used ( K , α , M ) = ( 2 , 0 , 1 ) under the PH scenario and ( K , α , M ) = ( 4 , 0 , 1 ) under the non-PH scenario. Complete sensitivity results for K, α , and M are provided in Table A2, Table A3 and Table A4.
In Scenario (1), where the PH assumption held (Table 1), the simulated data were generated fully in accordance with the modeling assumptions of the joint model. The joint model was therefore expected to achieve the best predictive performance. Empirically, the joint model outperformed the other benchmark models in both C td and AUC. TCN-DCM yielded C td values of approximately 0.77–0.79, all AUC values exceeded 0.75, and all BS values were below 0.05, indicating favorable predictive performance on longitudinal data satisfying the PH assumption. TCN-DCM also generally outperformed RDSM and DDH, and its advantage did not diminish as the prediction horizon increased.
In Scenario (2), where the PH assumption was violated (Table 2), RDSM and TCN-DCM showed clearly superior predictive performance in different respects. The C td of TCN-DCM remained close to 0.6, and all AUC values exceeded 0.6, whereas RDSM achieved lower BS values. Thus, TCN-DCM and RDSM showed comparable overall performance for longitudinal data violating the PH assumption. DDH was markedly weaker in both discrimination and prediction error, indicating limited suitability for this simulated non-PH setting. The C td and AUC of the joint model were lower than those of TCN-DCM and RDSM, while its BS was close to that of RDSM and slightly better than that of TCN-DCM.
To compare the overall performance of TCN-DCM and RDSM under the non-PH scenario more formally, we conducted dataset-level paired analyses. After Holm correction, TCN-DCM achieved significantly higher C td at all four evaluation horizons and significantly higher AUC at years 2 and 3, whereas RDSM achieved significantly lower BS at all four horizons. Thus, neither model dominated consistently across all metrics: TCN-DCM provided stronger discrimination, while RDSM had a modest advantage in prediction error. Complete paired differences, bootstrap 95% confidence intervals, and Holm-adjusted p-values are provided in Table A11.
To assess robustness across different data conditions, we additionally examined sample sizes N = 300 , 500 , 1000 , target censoring rates of 20%, 40%, and 60%, and missing rates of 0%, 10%, and 30%, while holding the remaining data-generating mechanisms and model-training settings fixed. Twenty independent simulated datasets were generated for each setting, and the same twice-repeated five-fold cross-validation procedure as in the primary analysis was used. In both the PH and non-PH scenarios, increasing sample size generally improved C td and AUC and reduced the standard deviations of the metrics. Increasing missingness mainly reduced discrimination, with a more pronounced effect in the non-PH scenario. Across censoring rates of 20–60%, performance was generally stable, although some deterioration and greater variability appeared at higher censoring rates. Complete results are provided in Table A12, Table A13 and Table A14.

4. Real-World Case Analysis for Dynamic Risk Prediction

The dataset originates from a clinical trial for primary biliary cholangitis (PBC) conducted at the Mayo Clinic and is a well-known longitudinal survival dataset widely used for evaluating survival and dynamic prediction models [22,23]. Over the 10-year enrollment period of the PBC trial, a total of 424 patients diagnosed with PBC were referred to the Mayo Clinic and met the eligibility criteria for a randomized controlled trial comparing D-penicillamine with placebo. The first 312 enrolled patients participated in the randomized trial: 158 patients received D-penicillamine treatment, while the remaining 154 patients were assigned to the placebo group. An additional 112 patients declined participation in the randomized trial but consented to routine laboratory measurements and long-term survival follow-up.
Each patient in the cohort has longitudinal covariates collected at multiple follow-up time points, yielding a total of 1945 observational records. The dataset includes 20 variables: time to death or censoring, event indicator, treatment assignment, age, sex, serum bilirubin, albumin, diuretic use, prothrombin time, hepatomegaly, ascites, serum aspartate aminotransferase (AST) reflecting liver function, histological disease stage, and other clinical indicators.

4.1. Evaluation Results of Dynamic Prediction Models

According to the selection rules specified in Section 2.5.1 and Section 2.5.2, the final PBC analysis used ( K , α , M ) = ( 6 , 0 , 5 ) . Complete sensitivity results are provided in Table A1, Table A2, Table A3 and Table A4.
To evaluate the fit and generalizability of TCN-DCM on real-world data independently, we applied twice-repeated patient-level five-fold cross-validation to the PBC data. TCN-DCM maintained stable out-of-fold discrimination at all three evaluation horizons. Complete out-of-fold evaluation results and 95% confidence intervals are provided in Table A15.
Years 4, 6, and 8 were selected as prediction horizons. TCN-DCM and three competing models were used to predict individual survival probabilities up to these prespecified horizons. The C td , AUC, and BS results indicated strong overall performance of TCN-DCM (Table 3). TCN-DCM achieved the highest C td at all three horizons, the highest AUC at the first two horizons, and the lowest BS at year 4; its remaining metrics were also close to the best-performing competitor, indicating favorable overall predictive performance.
To examine the clinical interpretability of the latent Cox components, we further characterized the latent risk states identified by the final TCN-DCM model with K = 6 .
The six latent states showed an overall clinical gradient from relative stability to severe decompensation. States 1 and 2 primarily represented low and intermediate disease severity, respectively; States 3 and 4 were characterized as a rapid biochemical-progression state and a high-bilirubin state with hepatic signs. State 5 exhibited an advanced high-severity profile, whereas State 6 showed marked decompensation, including high bilirubin, low albumin, coagulation abnormalities, ascites, and edema. Complete profiles of the latent states are provided in Table A16.

4.2. Individual Dynamic Prediction Results

Three representative patients were selected from the PBC data to illustrate the dynamically predicted survival-probability curves generated by TCN-DCM. Patient 116 received D-penicillamine and remained alive throughout follow-up; Patients 104 and 90 also received D-penicillamine but died during follow-up. Figure 2, Figure 3 and Figure 4 show their dynamically predicted survival-probability curves at different observation times. Each curve corresponds to a prediction made at a particular observation time and incorporates only the longitudinal covariate information observed up to and including that time.
As follow-up information for Patient 116 accumulated, the model produced increasingly stable predictions. Based on baseline information at year 0, the model estimated a probability of death before year 9 exceeding 40%. After information at years 0.54 and 1.00 was incorporated under D-penicillamine treatment, the predicted mortality risk decreased substantially, with the estimated probability of death before year 9 falling below 25%. Predictions based on longitudinal information from years 2.11–7.36 showed a further decline and gradual stabilization of the predicted mortality risk.
Patient 104 showed a different dynamic pattern. The model produced relatively high predicted survival probabilities early in follow-up, but the curves shifted downward as new information was incorporated. Based on measurements from baseline through year 3.00, TCN-DCM did not identify the patient as being at high risk of death. As additional longitudinal information accumulated, the predicted survival curves declined progressively. After information at year 5.10 was incorporated, the model estimated an approximately 50% probability of death before year 8. Predictions based on measurements at years 6.11 and 7.11 indicated a further increase in estimated mortality risk.
For Patient 90, who also received D-penicillamine, the model produced a dynamic pattern similar to that of Patient 104, indicating a gradual increase in mortality risk over time.
Overall, the dynamic prediction results for these three patients demonstrate that the TCN-DCM model can continuously update individual survival probability estimates by integrating longitudinal covariate histories observed up to different time points. This provides a time-adaptive framework for individualized risk assessment during clinical follow-up.

5. Discussion

In this study, we proposed the TCN-DCM dynamic prediction model for longitudinal survival data. The model incorporates repeatedly observed covariate information and captures the temporal variation in time-varying covariates, enabling more comprehensive feature extraction for survival prediction. By combining temporal convolutional networks with the Deep Cox Mixtures framework, the proposed model provides a data-driven approach for dynamic survival prediction while relaxing the global PH assumption through latent risk components. Therefore, it retains a connection with classical survival analysis while improving the flexibility of risk modeling for longitudinal data.
The simulation experiments and real-data case analysis showed that TCN-DCM achieved robust predictive performance regardless of whether the PH assumption held or was violated. Further parameter-sensitivity, internal-ablation, random-initialization, and robustness analyses under varying sample sizes, censoring rates, and missing rates showed that TCN-DCM generally maintained stable C td , AUC, and BS performance under the prespecified experimental conditions. MCEM optimization also exhibited a high proportion of valid training histories and consistent convergence characteristics. Although some model components and parameter values produced modest performance changes, the main conclusions were consistent across experimental settings, supporting the numerical stability and predictive robustness of the proposed model. The individualized dynamic prediction analysis further illustrated how predicted survival probabilities were updated as longitudinal follow-up information accumulated, demonstrating the model’s ability to support time-updated individualized risk assessment. These results suggest that the proposed method can provide statistical support for identifying adverse-event risk and adapting risk-intervention strategies in medicine, engineering, economics, and related fields.

Supplementary Materials

The following supporting information can be downloaded at: https://www.mdpi.com/article/10.3390/math14152727/s1.

Author Contributions

Conceptualization, Y.H. (Yawen Hou); methodology, Y.H. (Youling Hu) and Y.H. (Yawen Hou); formal analysis, Y.H. (Youling Hu), G.S. and Y.H. (Yawen Hou); investigation, Y.H. (Youling Hu) and G.S.; software, G.S. and Y.H. (Youling Hu); writing—original draft preparation, Y.H. (Youling Hu) and Y.H. (Yawen Hou); writing—review and editing, Y.H. (Youling Hu) and Y.H. (Yawen Hou); supervision, Y.H. (Yawen Hou); project administration, Y.H. (Yawen Hou); funding acquisition, Y.H. (Yawen Hou). Y.H. (Youling Hu) and G.S. contributed equally to this work. All authors have read and agreed to the published version of the manuscript.

Funding

This research was funded by the National Social Science Fund of China, grant number 23BTJ045.

Data Availability Statement

The real-world dataset used in our case analysis is the primary biliary cholangitis (PBC) dataset, which is publicly available in the R package survival as the pbc and pbcseq datasets. The package can be downloaded from CRAN: https://CRAN.R-project.org/package=survival (accessed on 5 June 2026). The documentation for the two datasets is available at the following: https://stat.ethz.ch/R-manual/R-devel/library/survival/html/pbc.html (accessed on 5 June 2026), https://stat.ethz.ch/R-manual/R-devel/library/survival/html/pbcseq.html (accessed on 5 June 2026). Associated code is provided in Supplementary Material.

Conflicts of Interest

The authors declare no conflicts of interest.

Abbreviations

The following abbreviations are used in this manuscript:
ASTAspartate aminotransferase
AUCArea under the ROC curve
BSBrier score
DDHDynamic-DeepHit
DSMDeep survival machine
EMExpectation–maximization algorithm
IPCWInverse probability of censoring weights
JMJoint model
MCEMMonte Carlo expectation–maximization algorithm
PBCPrimary biliary cholangitis
PHProportional hazards
ReLURectified linear unit
RDSMRecurrent deep survival machine(s)
RNNRecurrent neural network
ROCReceiver operating characteristic curve
STSpecial treatment of listed securities
TCN-DCMTemporal Convolutional Network Deep Cox Mixtures Model
VAEVariational autoencoder

Appendix A. Supplementary Analyses

Appendix A.1. Internal Ablation and Hyperparameter Sensitivity Analyses

In Table A1, the masked causal dilated TCN was replaced by landmark-safe cumulative mean pooling, while the latent Cox mixture structure and all remaining training settings were retained. The final configurations were K , α , M = ( 2 , 0 , 1 ) , 4 , 0 , 1 , and 6 , 0 , 5 for the PH, non-PH, and PBC analyses, respectively.
In Table A2, the K = 1 configuration corresponds to the TCN-Cox ablation, in which the multi-component latent-mixture and component-assignment mechanisms were removed. Bold type indicates the configuration selected according to the prespecified Score-based parsimony rule.
In Table A3, K was fixed at 2, 4, and 6 for the PH, non-PH, and PBC analyses, respectively, and M was fixed at the value shown in the table. Bold type indicates the configuration selected according to the prespecified Score-based parsimony rule.
In Table A4, K was fixed at the selected scenario-specific value and α = 0 . Bold type indicates the configuration selected according to the prespecified Score-based parsimony rule.
Table A1. Ablation of the temporal-representation module.
Table A1. Ablation of the temporal-representation module.
ScenarioTemporal RepresentationMean CtdMean AUCMean BSScore
PHMasked causal dilated TCN0.78340.78780.02590.8484
PHMean-pooling DCM0.78270.78790.02680.8480
non-PHMasked causal dilated TCN0.59460.60200.10130.6984
non-PHMean-pooling DCM0.59210.60180.10210.6973
PBCMasked causal dilated TCN0.81330.85430.15500.8375
PBCMean-pooling DCM0.79150.83650.15840.8232
Note: Bold type identifies the masked causal dilated TCN representation retained in the final model for each scenario.
Table A2. Sensitivity to the number of latent Cox components.
Table A2. Sensitivity to the number of latent Cox components.
ScenarioKMean CtdMean AUCMean BSScore (SD)
PH10.71470.71660.02370.8025 (0.0355)
PH20.79570.79960.02620.8563 (0.0309)
PH30.78350.78730.02620.8482 (0.0345)
PH40.78100.78400.02610.8463 (0.0354)
PH50.79320.79760.02580.8550 (0.0354)
PH60.79750.80140.02510.8579 (0.0318)
non-PH10.57370.57970.09770.6852 (0.0227)
non-PH20.58270.58970.10110.6904 (0.0205)
non-PH30.59060.59730.10260.6951 (0.0183)
non-PH40.59390.60060.10130.6978 (0.0183)
non-PH50.59760.60460.10230.7000 (0.0191)
non-PH60.59980.60760.10220.7017 (0.0199)
PBC10.76560.80380.16610.8011 (0.0324)
PBC20.78970.82990.15870.8203 (0.0366)
PBC30.80030.83870.15900.8267 (0.0328)
PBC40.80380.84250.15140.8316 (0.0422)
PBC50.80240.84270.15860.8288 (0.0343)
PBC60.81270.85320.15360.8374 (0.0410)
Note: Bold type indicates the configuration selected according to the prespecified Score-based parsimony rule.
Table A3. Sensitivity to the VAE regularization weight.
Table A3. Sensitivity to the VAE regularization weight.
ScenarioVAE Weight (α)Fixed MMean CtdMean AUCMean BSScore
PH010.79310.79640.02700.8542
PH0.0110.79600.79980.02600.8566
PH0.110.79340.79720.02640.8547
PH110.79690.80050.02630.8571
non-PH010.59460.60200.10130.6984
non-PH0.0110.59390.60060.10130.6978
non-PH0.110.59530.60210.10130.6987
non-PH110.59620.60300.10140.6993
PBC050.81330.85420.15500.8375
PBC0.0150.80780.84930.15650.8335
PBC0.150.80400.84630.15740.8310
PBC150.80880.85020.15590.8344
Note: Bold type indicates the configuration selected according to the prespecified Score-based parsimony rule.
Table A4. Sensitivity to the number of Monte Carlo draws.
Table A4. Sensitivity to the number of Monte Carlo draws.
ScenarioMFixed (α)Mean CtdMean AUCMean BSScore
PH100.79310.79640.02700.8542
PH500.79550.79940.02700.8559
PH1000.79460.79880.02610.8558
non-PH100.59460.60200.10130.6984
non-PH500.59480.60180.10070.6987
non-PH1000.59180.59870.10260.6960
PBC100.79490.83350.15770.8236
PBC500.81330.85420.15500.8375
PBC1000.80810.84870.15050.8354
Note: Bold type indicates the configuration selected according to the prespecified Score-based parsimony rule.

Appendix A.2. Sensitivity to Random Initialization

Table A5. Sensitivity to random initialization in the PH scenario.
Table A5. Sensitivity to random initialization in the PH scenario.
Random SeedCtdAUCBSScore Mean (SD)
110.72370.72850.01610.8120 (0.1184)
1110.74580.75480.01710.8278 (0.0893)
20260.72180.72640.01780.8101 (0.1180)
99990.74420.74970.01770.8254 (0.0986)
Median0.73400.73910.01740.8187 (0.1083)
Table A6. Sensitivity to random initialization in the non-PH scenario.
Table A6. Sensitivity to random initialization in the non-PH scenario.
Random SeedCtdAUCBSScore Mean (SD)
110.55720.56820.09400.6771 (0.0310)
1110.56640.57360.09630.6812 (0.0288)
20260.56330.57110.09420.6801 (0.0455)
99990.57230.57980.09310.6864 (0.0315)
Median0.56490.57240.09410.6807 (0.0313)
Table A7. Sensitivity to random initialization in the PBC data.
Table A7. Sensitivity to random initialization in the PBC data.
Random SeedCtdAUCBSScore Mean (SD)
110.79660.83140.16060.8225 (0.0498)
1110.81090.84990.15370.8357 (0.0439)
20260.80090.83340.16180.8242 (0.0582)
99990.80720.84260.15470.8317 (0.0436)
Median0.80410.83800.15770.8280 (0.0469)

Appendix A.3. Fold-Level Numerical Convergence Diagnostics

Table A8. Fold-level numerical convergence diagnostics for TCN-DCM in the PH simulation.
Table A8. Fold-level numerical convergence diagnostics for TCN-DCM in the PH simulation.
RepeatFoldBest-Validation EpochStopping EpochMinimum Validation LossValidation Loss at Stopping
1143.048.54.95636.0216
1254.060.56.17337.2137
1345.550.54.57565.2237
1461.069.04.41884.8979
1563.567.05.85206.2788
211.04.010.564910.7012
2255.567.05.81936.7646
2349.057.54.70205.2775
2468.082.06.28416.9319
2550.055.05.13675.6402
Summary 52.0(46.4–59.6)59.0(51.6–67.0)5.4780(4.7656–6.0930)6.1502(5.3682–6.8900)
Note: Bold type identifies the summary row. Summary values are presented as median (IQR).
Table A9. Fold-level numerical convergence diagnostics for TCN-DCM in the non-PH simulation.
Table A9. Fold-level numerical convergence diagnostics for TCN-DCM in the non-PH simulation.
RepeatFoldBest-Validation EpochStopping EpochMinimum Validation LossValidation Loss at Stopping
1119.524.555.854556.4814
1218.022.555.711556.1261
1312.522.553.823254.4259
1412.023.559.607460.2503
1523.034.052.528152.9084
2111.518.058.809859.3674
2221.527.555.373755.5861
2330.533.555.957456.7735
2420.530.553.292554.9849
257.514.057.077357.3991
Summary18.8(12.1–21.3)24.0(22.5–29.8)55.7830(54.2108–56.7973)56.3037(55.1352–57.2427)
Note: Bold type identifies the summary row. Summary values are presented as median (IQR).
Table A10. Fold-level numerical convergence diagnostics for TCN-DCM on the PBC data.
Table A10. Fold-level numerical convergence diagnostics for TCN-DCM on the PBC data.
RepeatFoldBest-Validation EpochStopping EpochMinimum Validation LossValidation Loss at Stopping
11414413.317313.8697
12424515.690216.2296
13363918.595718.7610
14434617.457817.7784
15537614.912815.3553
21274118.283619.1564
22374012.706013.0404
23545712.608312.9675
24828515.549317.1518
25404112.516312.8199
Summary41.5 (37.8–50.5)44.5 (41.0–54.3)15.2311 (12.8588–17.0159)15.7925 (13.2477–17.6218)
Note: Bold type identifies the summary row. Summary values are presented as median (IQR).

Appendix A.4. Dataset-Level Paired Comparison

Table A11. Dataset-level paired comparison of TCN-DCM and RDSM in the non-PH simulation.
Table A11. Dataset-level paired comparison of TCN-DCM and RDSM in the non-PH simulation.
MetricPrediction Horizon, YearsPaired Difference ΔBootstrap 95% CIHolm-Adjusted p-Value
C td 20.02000.0086–0.03310.0092
C td 30.01790.0054–0.03050.0110
C td 40.01670.0040–0.02920.0076
C td 50.01670.0047–0.02900.0092
AUC20.01870.0059–0.03270.0155
AUC30.01580.0035–0.02830.0335
AUC40.01410.0036–0.02520.0739
AUC50.01350.0015–0.02570.0577
BS2−0.0012−0.0018–0.00060.0043
BS3−0.0026−0.0038–0.00140.0020
BS4−0.0042−0.0059–0.00240.0015
BS5−0.0057−0.0081–0.00320.0020
Note: Within each dataset and prediction horizon, results from the twice-repeated five-fold cross-validation were averaged before the paired analysis. For C td and AUC, the paired difference was defined as Δ = TCN - DCM RDSM . For BS, the paired difference was defined as Δ = BS RDSM BS TCN DCM . Positive values therefore favor TCN-DCM, whereas negative values favor RDSM. The 95% confidence intervals were obtained from 1000 dataset-level bootstrap resamples. The p-values were obtained from two-sided Wilcoxon signed-rank tests and adjusted using the Holm procedure across the comparisons of TCN-DCM with RDSM, DDH, and JM within each metric and prediction horizon.

Appendix A.5. Robustness Under Varying Data Conditions

Table A12. Sensitivity to sample size.
Table A12. Sensitivity to sample size.
ScenarioSample SizeHorizon (Years)Ctd Mean (SD)AUC Mean (SD)BS Mean (SD)
PH30020.7901 (0.0227)0.8178 (0.0231)0.1296 (0.0122)
PH30030.7878 (0.0221)0.8275 (0.0223)0.1526 (0.0143)
PH30040.7851 (0.0217)0.8352 (0.0227)0.1628 (0.0152)
PH30050.7821 (0.0216)0.8404 (0.0234)0.1674 (0.0158)
PH50020.7974 (0.0178)0.8266 (0.0190)0.1249 (0.0077)
PH50030.7932 (0.0188)0.8335 (0.0208)0.1468 (0.0106)
PH50040.7895 (0.0179)0.8392 (0.0199)0.1579 (0.0119)
PH50050.7865 (0.0177)0.8449 (0.0199)0.1622 (0.0127)
PH100020.8089 (0.0090)0.8395 (0.0093)0.1170 (0.0048)
PH100030.8048 (0.0090)0.8469 (0.0095)0.1373 (0.0059)
PH100040.8017 (0.0092)0.8538 (0.0103)0.1464 (0.0069)
PH100050.7994 (0.0096)0.8605 (0.0108)0.1489 (0.0068)
non-PH30020.5677 (0.0453)0.5711 (0.0464)0.0648 (0.0061)
non-PH30030.5681 (0.0453)0.5732 (0.0471)0.0934 (0.0088)
non-PH30040.5685 (0.0459)0.5753 (0.0487)0.1197 (0.0112)
non-PH30050.5684 (0.0472)0.5769 (0.0513)0.1436 (0.0133)
non-PH50020.5909 (0.0292)0.5943 (0.0304)0.0653 (0.0039)
non-PH50030.5913 (0.0292)0.5964 (0.0311)0.0932 (0.0054)
non-PH50040.5921 (0.0291)0.5988 (0.0318)0.1182 (0.0066)
non-PH50050.5926 (0.0286)0.6010 (0.0320)0.1406 (0.0075)
non-PH100020.6121 (0.0238)0.6172 (0.0243)0.0624 (0.0020)
non-PH100030.6115 (0.0239)0.6191 (0.0248)0.0891 (0.0029)
non-PH100040.6111 (0.0241)0.6211 (0.0254)0.1129 (0.0037)
non-PH100050.6109 (0.0242)0.6235 (0.0259)0.1341 (0.0044)
Table A13. Sensitivity to the target censoring rate.
Table A13. Sensitivity to the target censoring rate.
ScenarioTarget Censoring RateHorizon (Years)Ctd Mean (SD)AUC Mean (SD)BS Mean (SD)
PH20%20.8023 (0.0150)0.8308 (0.0155)0.1193 (0.0071)
PH20%30.7983 (0.0155)0.8378 (0.0164)0.1411 (0.0090)
PH20%40.7952 (0.0153)0.8448 (0.0164)0.1515 (0.0102)
PH20%50.7933 (0.0158)0.8520 (0.0176)0.1552 (0.0115)
PH40%20.8002 (0.0164)0.8301 (0.0171)0.1239 (0.0085)
PH40%30.7953 (0.0172)0.8363 (0.0180)0.1449 (0.0100)
PH40%40.7918 (0.0171)0.8423 (0.0185)0.1553 (0.0116)
PH40%50.7889 (0.0169)0.8477 (0.0181)0.1591 (0.0121)
PH60%20.8001 (0.0221)0.8322 (0.0249)0.1277 (0.0137)
PH60%30.7938 (0.0231)0.8376 (0.0270)0.1492 (0.0179)
PH60%40.7887 (0.0243)0.8425 (0.0275)0.1568 (0.0209)
PH60%50.7850 (0.0237)0.8490 (0.0254)0.1563 (0.0219)
non-PH20%20.5907 (0.0237)0.5953 (0.0249)0.0648 (0.0046)
non-PH20%30.5912 (0.0238)0.5981 (0.0258)0.0929 (0.0064)
non-PH20%40.5915 (0.0236)0.6008 (0.0264)0.1179 (0.0080)
non-PH20%50.5915 (0.0233)0.6030 (0.0269)0.1404 (0.0092)
non-PH40%20.5958 (0.0247)0.5996 (0.0258)0.0636 (0.0043)
non-PH40%30.5955 (0.0245)0.6011 (0.0260)0.0914 (0.0064)
non-PH40%40.5953 (0.0245)0.6028 (0.0265)0.1166 (0.0082)
non-PH40%50.5950 (0.0246)0.6044 (0.0272)0.1390 (0.0097)
non-PH60%20.5830 (0.0257)0.5878 (0.0264)0.0662 (0.0036)
non-PH60%30.5826 (0.0260)0.5897 (0.0272)0.0948 (0.0052)
non-PH60%40.5825 (0.0264)0.5919 (0.0280)0.1204 (0.0065)
non-PH60%50.5822 (0.0270)0.5938 (0.0290)0.1434 (0.0075)
Table A14. Sensitivity to the missing rate.
Table A14. Sensitivity to the missing rate.
ScenarioMissing RateHorizon (Years) C td Mean (SD)AUC Mean (SD)BS Mean (SD)
PH0%20.8002 (0.0155)0.8288 (0.0159)0.1226 (0.0067)
PH0%30.7970 (0.0161)0.8372 (0.0170)0.1443 (0.0092)
PH0%40.7939 (0.0164)0.8441 (0.0174)0.1546 (0.0106)
PH0%50.7909 (0.0162)0.8498 (0.0177)0.1590 (0.0114)
PH10%20.7972 (0.0161)0.8261 (0.0164)0.1229 (0.0087)
PH10%30.7916 (0.0160)0.8314 (0.0160)0.1451 (0.0102)
PH10%40.7885 (0.0169)0.8381 (0.0180)0.1554 (0.0119)
PH10%50.7869 (0.0173)0.8457 (0.0195)0.1588 (0.0130)
PH30%20.7810 (0.0129)0.8093 (0.0132)0.1257 (0.0060)
PH30%30.7762 (0.0118)0.8151 (0.0119)0.1502 (0.0065)
PH30%40.7730 (0.0114)0.8216 (0.0114)0.1628 (0.0070)
PH30%50.7705 (0.0115)0.8273 (0.0126)0.1686 (0.0075)
non-PH0%20.5954 (0.0313)0.6001 (0.0315)0.0652 (0.0041)
non-PH0%30.5956 (0.0316)0.6026 (0.0321)0.0931 (0.0053)
non-PH0%40.5953 (0.0324)0.6046 (0.0335)0.1183 (0.0063)
non-PH0%50.5948 (0.0334)0.6063 (0.0350)0.1409 (0.0070)
non-PH10%20.5817 (0.0278)0.5855 (0.0287)0.0639 (0.0053)
non-PH10%30.5817 (0.0289)0.5875 (0.0305)0.0916 (0.0076)
non-PH10%40.5812 (0.0301)0.5889 (0.0324)0.1164 (0.0093)
non-PH10%50.5801 (0.0314)0.5895 (0.0347)0.1387 (0.0103)
non-PH30%20.5586 (0.0313)0.5628 (0.0337)0.0651 (0.0043)
non-PH30%30.5581 (0.0318)0.5643 (0.0356)0.0923 (0.0064)
non-PH30%40.5574 (0.0322)0.5655 (0.0375)0.1168 (0.0078)
non-PH30%50.5568 (0.0332)0.5667 (0.0401)0.1388 (0.0091)
Note: Each condition included 20 independently simulated datasets. Within each dataset, results from the twice-repeated five-fold cross-validation were first aggregated, after which the independent dataset was treated as the statistical unit. Values are reported as mean (SD) across the independent datasets. Only one design factor was varied at a time, while all remaining data-generating and training settings were held fixed.

Appendix A.6. PBC Out-of-Fold Evaluation

Table A15. Repeated-cross-validation out-of-fold evaluation of TCN-DCM on the PBC data.
Table A15. Repeated-cross-validation out-of-fold evaluation of TCN-DCM on the PBC data.
Evaluation MetricEvaluation Horizon (Years)MeanSD95% CI
C td 40.83390.03080.8146–0.8523
C td 60.79900.02950.7800–0.8154
C td 80.76800.03030.7490–0.7846
AUC40.87340.03270.8541–0.8911
AUC60.83730.03960.8142–0.8609
AUC80.80540.04140.7804–0.8285
BS40.12660.03750.1063–0.1495
BS60.16260.04890.1364–0.1942
BS80.18780.04480.1627–0.2144
Note: The 95% confidence intervals were obtained from 1000 bootstrap resamples.

Appendix A.7. Clinical Interpretation of the Six Latent Risk States

Table A16. Clinical characteristics of the six latent risk states identified by TCN-DCM in the PBC data.
Table A16. Clinical characteristics of the six latent risk states identified by TCN-DCM in the PBC data.
Clinical CharacteristicState 1State 2State 3State 4State 5State 6
Risk-state labelLow-severity stable stateIntermediate-severity stateRapid biochemical-progression stateHigh-bilirubin state with hepatic signsAdvanced high-severity stateSevere decompensated state
Patients, n (%)136 (43.6%)67 (21.5%)6 (1.9%)8 (2.6%)22 (7.1%)73 (23.4%)
Maximum component-assignment probability, median (IQR)0.34 (0.29, 0.41)0.31 (0.23, 0.43)0.25 (0.22, 0.32)0.29 (0.23, 0.37)0.32 (0.28, 0.36)0.38 (0.25, 0.53)
Baseline bilirubin, mg/dL0.90 (0.60, 1.40)1.30 (0.80, 2.55)3.35 (1.40, 5.45)4.20 (2.20, 5.38)3.35 (1.90, 6.23)5.20 (2.10, 11.40)
Annual log-bilirubin slope0.03 (0.00, 0.13)0.06 (0.00, 0.23)0.25 (0.09, 0.43)0.23 (0.14, 0.32)0.10 (0.02, 0.27)0.13 (0.00, 0.32)
Baseline albumin, g/dL3.67 (3.50, 3.89)3.60 (3.37, 3.87)3.40 (3.24, 3.67)3.56 (3.33, 3.69)3.45 (3.26, 3.60)3.20 (2.94, 3.45)
Baseline prothrombin time10.20 (9.80, 10.60)10.60 (10.00, 11.00)10.45 (10.30, 10.97)10.65 (10.23, 10.90)11.00 (10.43, 11.55)11.50 (11.00, 12.20)
Baseline histologic stage3.00 (2.00, 3.00)3.00 (2.00, 4.00)3.00 (3.00, 3.75)3.00 (3.00, 3.25)4.00 (3.00, 4.00)4.00 (3.00, 4.00)
Hepatomegaly, n (%)40 (29.4%)26 (38.8%)5 (83.3%)6 (75.0%)18 (81.8%)65 (89.0%)
Ascites, n (%)1 (0.7%)0 (0.0%)0 (0.0%)0 (0.0%)0 (0.0%)23 (31.5%)
Any edema, n (%)13 (9.6%)9 (13.4%)0 (0.0%)0 (0.0%)5 (22.7%)38 (52.1%)
Deaths, n (%)26 (19.1%)27 (40.3%)5 (83.3%)7 (87.5%)13 (59.1%)62 (84.9%)
Note: Continuous variables are presented as median (IQR), and categorical variables as n (%). ’Any edema’ includes mild and moderate-to-severe edema.

References

  1. Diggle, P.J.; Heagerty, P.J.; Liang, K.Y.; Zeger, S.L. Analysis of Longitudinal Data; Oxford University Press: Oxford, UK, 2002. [Google Scholar]
  2. Asgari, S.; Khalili, D.; Zayeri, F.; Azizi, F.; Hadaegh, F. Dynamic Prediction Models Improved the Risk Classification of Type 2 Diabetes Compared with Classical Static Models. J. Clin. Epidemiol. 2021, 140, 33–43. [Google Scholar] [CrossRef]
  3. Achakzai, M.A.K.; Peng, J. Detecting Financial Statement Fraud Using Dynamic Ensemble Machine Learning. Int. Rev. Financ. Anal. 2023, 89, 102827. [Google Scholar] [CrossRef]
  4. Wulfsohn, M.S.; Tsiatis, A.A. A Joint Model for Survival and Longitudinal Data Measured with Error. Biometrics 1997, 53, 330–339. [Google Scholar] [CrossRef]
  5. van Houwelingen, H.C. Dynamic Prediction by Landmarking in Event History Analysis. Scand. J. Stat. 2007, 34, 70–85. [Google Scholar] [CrossRef]
  6. Lee, C.; Yoon, J.; van der Schaar, M. Dynamic-DeepHit: A Deep Learning Approach for Dynamic Survival Analysis With Competing Risks Based on Longitudinal Data. IEEE Trans. Biomed. Eng. 2020, 67, 122–133. [Google Scholar] [CrossRef] [PubMed]
  7. Howle, L.E.; Weber, P.W.; Nichols, J.M. Bayesian Approach to Decompression Sickness Model Parameter Estimation. Comput. Biol. Med. 2017, 82, 3–11. [Google Scholar] [CrossRef] [PubMed]
  8. Andrinopoulou, E.R.; Nasserinejad, K.; Szczesniak, R.; Rizopoulos, D. Integrating Latent Classes in the Bayesian Shared Parameter Joint Model of Longitudinal and Survival Outcomes. Stat. Methods Med. Res. 2020, 29, 3294–3307. [Google Scholar] [CrossRef] [PubMed]
  9. Rizopoulos, D.; Molenberghs, G.; Lesaffre, E.M.E.H. Dynamic Predictions with Time-Dependent Covariates in Survival Analysis Using Joint Modeling and Landmarking. Biom. J. 2017, 59, 1261–1276. [Google Scholar] [CrossRef] [PubMed]
  10. Rizopoulos, D.; Taylor, J.M.G. Optimizing Dynamic Predictions from Joint Models Using Super Learning. Stat. Med. 2024, 43, 1315–1328. [Google Scholar] [CrossRef] [PubMed]
  11. Nagpal, C.; Li, X.; Dubrawski, A. Deep Survival Machines: Fully Parametric Survival Regression and Representation Learning for Censored Data With Competing Risks. IEEE J. Biomed. Health Inform. 2021, 25, 3163–3175. [Google Scholar] [CrossRef] [PubMed]
  12. Nagpal, C.; Jeanselme, V.; Dubrawski, A. Deep Parametric Time-to-Event Regression with Time-Varying Covariates. In Proceedings of Machine Learning Research, Proceedings of the AAAI Spring Symposium on Survival Prediction—Algorithms, Challenges, and Applications, Stanford University, Palo Alto, CA, USA, 22–24 March 2021; PMLR: Cambridge, MA, USA, 2021; Volume 146, pp. 184–193. [Google Scholar]
  13. Zeng, L.; Zhang, J.; Chen, W.; Ding, Y. tdCoxSNN: Time-Dependent Cox Survival Neural Network for Continuous-Time Dynamic Prediction. J. R. Stat. Soc. Ser. C Appl. Stat. 2025, 74, 187–203. [Google Scholar] [CrossRef] [PubMed]
  14. Mesinovic, M.; Watkinson, P.; Zhu, T. DySurv: Dynamic Deep Learning Model for Survival Analysis with Conditional Variational Inference. J. Am. Med. Inform. Assoc. 2026, 33, 112–122. [Google Scholar] [CrossRef] [PubMed]
  15. Nagpal, C.; Yadlowsky, S.; Rostamzadeh, N.; Heller, K. Deep Cox Mixtures for Survival Regression. In Proceedings of Machine Learning Research, Proceedings of the 6th Machine Learning for Healthcare Conference, Virtual Event, 6–7 August 2021; PMLR: Cambridge, MA, USA, 2021; Volume 149, pp. 674–708. [Google Scholar]
  16. Dempster, A.P.; Laird, N.M.; Rubin, D.B. Maximum Likelihood from Incomplete Data via the EM Algorithm. J. R. Stat. Soc. Ser. B Stat. Methodol. 1977, 39, 1–22. [Google Scholar] [CrossRef]
  17. Wei, G.C.G.; Tanner, M.A. A Monte Carlo Implementation of the EM Algorithm and the Poor Man’s Data Augmentation Algorithms. J. Am. Stat. Assoc. 1990, 85, 699–704. [Google Scholar] [CrossRef]
  18. Kingma, D.P.; Welling, M. Auto-Encoding Variational Bayes. In Proceedings of the 2nd International Conference on Learning Representations, Banff, AB, Canada, 14–16 April 2014. [Google Scholar]
  19. Pickett, K.L.; Suresh, K.; Campbell, K.R.; Davis, S.; Juarez-Colunga, E. Random Survival Forests for Dynamic Predictions of a Time-to-Event Outcome Using a Longitudinal Biomarker. BMC Med. Res. Methodol. 2021, 21, 216. [Google Scholar] [CrossRef] [PubMed]
  20. Gerds, T.A.; Kattan, M.W.; Schumacher, M.; Yu, C. Estimating a Time-Dependent Concordance Index for Survival Prediction Models with Covariate Dependent Censoring. Stat. Med. 2013, 32, 2173–2184. [Google Scholar] [CrossRef] [PubMed]
  21. Hung, H.; Chiang, C.T. Optimal Composite Markers for Time-Dependent Receiver Operating Characteristic Curves with Censored Survival Data. Scand. J. Stat. 2010, 37, 664–679. [Google Scholar] [CrossRef]
  22. Rustand, D.; van Niekerk, J.; Krainski, E.T.; Rue, H.; Proust-Lima, C. Fast and Flexible Inference for Joint Models of Multivariate Longitudinal and Survival Data Using Integrated Nested Laplace Approximations. Biostatistics 2024, 25, 429–448. [Google Scholar] [CrossRef] [PubMed]
  23. Dickson, E.R.; Grambsch, P.M.; Fleming, T.R.; Fisher, L.D.; Langworthy, A. Prognosis in Primary Biliary Cirrhosis: Model for Decision Making. Hepatology 1989, 10, 1–7. [Google Scholar] [CrossRef] [PubMed]
Figure 1. Temporal convolutional network Deep Cox Mixtures model.
Figure 1. Temporal convolutional network Deep Cox Mixtures model.
Mathematics 14 02727 g001
Figure 2. Dynamically predicted survival-probability curves for Patient 116 in the D-penicillamine group. Patient 116 remained alive during follow-up.
Figure 2. Dynamically predicted survival-probability curves for Patient 116 in the D-penicillamine group. Patient 116 remained alive during follow-up.
Mathematics 14 02727 g002
Figure 3. Dynamically predicted survival-probability curves for Patient 104 in the D-penicillamine group. Patient 104 died during follow-up.
Figure 3. Dynamically predicted survival-probability curves for Patient 104 in the D-penicillamine group. Patient 104 died during follow-up.
Mathematics 14 02727 g003
Figure 4. Dynamically predicted survival-probability curves for Patient 90 in the D-penicillamine group. Patient 90 died during follow-up.
Figure 4. Dynamically predicted survival-probability curves for Patient 90 in the D-penicillamine group. Patient 90 died during follow-up.
Mathematics 14 02727 g004
Table 1. Simulation performance of survival data under the PH assumption.
Table 1. Simulation performance of survival data under the PH assumption.
TCN-DCMRDSMDDHJM
MetricHorizonMeanSDMeanSDMeanSDMeanSD
C td t = 2 0.77890.05380.72850.07290.55090.07880.83070.0606
t = 3 0.78750.04380.73180.07310.55390.07620.82820.0616
t = 4 0.78510.04790.73000.07500.54780.08290.82440.0627
t = 5 0.78520.04930.72800.07550.55170.08380.81920.0644
AUC t = 2 0.78170.05350.72930.07400.54510.07840.83650.0616
t = 3 0.79150.04340.73330.07500.54600.07540.83620.0628
t = 4 0.78980.04880.73250.07770.53530.08260.83470.0641
t = 5 0.79080.05060.73000.07880.53440.08470.83210.0665
BS t = 2 0.01400.00360.01260.00290.01240.00270.01310.0025
t = 3 0.02280.00540.01970.00410.01970.00410.02020.0036
t = 4 0.03150.00680.02680.00510.02720.00530.02690.0046
t = 5 0.04040.00850.03440.00630.03540.00700.03390.0058
Note: Bold type indicates the best mean performance at each prediction horizon; tied best means are all shown in bold. Higher C td and AUC values and lower BS values indicate better predictive performance.
Table 2. Simulation performance of survival data under violation of the PH assumption.
Table 2. Simulation performance of survival data under violation of the PH assumption.
TCN-DCMRDSMDDHJM
MetricHorizonMeanSDMeanSDMeanSDMeanSD
C td t = 2 0.59770.03260.57770.01980.53510.03370.52640.0262
t = 3 0.59750.03300.57960.02070.53460.03400.52850.0282
t = 4 0.59680.03330.58010.02190.53390.03230.52970.0301
t = 5 0.59620.03400.57960.02260.53430.03080.53010.0311
AUC t = 2 0.60360.03320.58490.02130.51400.03500.53020.0259
t = 3 0.60610.03400.59030.02290.50430.03580.53410.0279
t = 4 0.60810.03470.59410.02500.49450.03440.53700.0300
t = 5 0.61020.03580.59670.02640.48710.03310.53910.0312
BS t = 2 0.06290.00500.06170.00470.12460.02110.06170.0048
t = 3 0.08960.00710.08700.00650.28060.05710.08730.0066
t = 4 0.11370.00930.10950.00790.29350.05540.11030.0081
t = 5 0.13500.01150.12940.00920.30530.05410.13070.0093
Note: Bold type indicates the best mean performance at each prediction horizon; tied best means are all shown in bold. Higher C td and AUC values and lower BS values indicate better predictive performance.
Table 3. Prediction performance of different models on the PBC dataset.
Table 3. Prediction performance of different models on the PBC dataset.
TCN-DCMRDSMDDHJM
MetricHorizonMeanSDMeanSDMeanSDMeanSD
C td t = 4 0.83390.03080.81430.04610.68000.13210.79940.0390
t = 6 0.79900.02950.78460.04530.67210.10710.77660.0428
t = 8 0.76800.03030.75300.04230.62240.14220.74950.0463
AUC t = 4 0.87340.03270.85360.05430.69970.15290.84130.0395
t = 6 0.83730.03960.82540.06590.69590.12200.82460.0554
t = 8 0.80540.04140.78970.06960.63180.17110.80610.0606
BS t = 4 0.12660.03750.13290.04010.20460.07200.13950.0306
t = 6 0.16260.04890.16020.04380.25190.09300.16520.0384
t = 8 0.18780.04480.18910.04150.30550.12200.18220.0405
Note: Bold type indicates the best mean performance at each prediction horizon. Higher C td and AUC values and lower BS values indicate better predictive performance.
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Hu, Y.; Su, G.; Hou, Y. A Temporal Convolutional Network Deep Cox Mixtures Model for Dynamic Risk Prediction. Mathematics 2026, 14, 2727. https://doi.org/10.3390/math14152727

AMA Style

Hu Y, Su G, Hou Y. A Temporal Convolutional Network Deep Cox Mixtures Model for Dynamic Risk Prediction. Mathematics. 2026; 14(15):2727. https://doi.org/10.3390/math14152727

Chicago/Turabian Style

Hu, Youling, Guina Su, and Yawen Hou. 2026. "A Temporal Convolutional Network Deep Cox Mixtures Model for Dynamic Risk Prediction" Mathematics 14, no. 15: 2727. https://doi.org/10.3390/math14152727

APA Style

Hu, Y., Su, G., & Hou, Y. (2026). A Temporal Convolutional Network Deep Cox Mixtures Model for Dynamic Risk Prediction. Mathematics, 14(15), 2727. https://doi.org/10.3390/math14152727

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop