Tutorials › Competing Risks and Multi-State Models › Stratification Versus Covariate Adjustment Across Transitions

Regression for Multi-State Data · Tutorial 366 of 699

Stratification Versus Covariate Adjustment Across Transitions

Learn when to stratify transition hazards by a factor and when to estimate its regression coefficient, and how these choices change the model’s assumptions and interpretation.

Advanced 13 min read

What You'll Learn

  • Distinguish stratifying baseline hazards by transition from stratifying them by a covariate factor.
  • Write factor-stratified and factor-adjusted transition-hazard models.
  • Derive the partial-likelihood contribution under each approach.
  • Recognize when a common factor hazard ratio is too restrictive.
  • Assess trade-offs in interpretation, precision, and data requirements.

Two Different Ways to Represent a Factor

A transition regression model must allow hazards to differ between transitions, but it must also decide how to represent patient or process characteristics. For a categorical factor such as treatment group or disease subtype, two common choices are to estimate a regression coefficient or to let the baseline hazard vary freely across factor levels. These are not interchangeable: a coefficient estimates a particular covariate effect, while factor stratification controls for group differences without estimating that effect.

It is also important to distinguish stratifying by transition from stratifying by a covariate factor. The first permits a different baseline hazard for each transition. The second permits a different baseline hazard for each level of a factor within a transition. A model can do both.

Definition: Let \(r=(h,j)\) denote a possible transition from state \(h\) to state \(j\), \(Y_{ir}(t)\) indicate that individual \(i\) is at risk for transition \(r\) at time \(t\), \(Z_i\) be a categorical factor, and \(W_i\) be other covariates. A factor-adjusted Cox model for transition \(r\) can be written \(\lambda_{ir}(t)=Y_{ir}(t)\lambda^0_r(t)\exp\{\gamma_r Z_i+\beta_r^\mathsf{T}W_i\}\) for a binary \(Z_i\). A factor-stratified model replaces the single baseline hazard by \(\lambda^0_{r,Z_i}(t)\) and omits \(\gamma_r Z_i\): \(\lambda_{ir}(t)=Y_{ir}(t)\lambda^0_{r,Z_i}(t)\exp\{\beta_r^\mathsf{T}W_i\}\).

For a factor with more than two levels, the adjustment model uses indicator variables and corresponding coefficients (with a reference level), whereas the stratified model has a separate baseline hazard for each level. In either specification, transition \(r\) has its own baseline hazard unless additional restrictions are imposed. The coefficients \(\beta_r\) may also be transition-specific; using a common coefficient across transitions is a separate modeling restriction.

What Each Choice Assumes and Estimates

With adjustment, the factor’s effect on transition \(r\) is represented by a hazard ratio. For binary \(Z\), the model says that, holding \(W\) fixed, the hazard ratio for \(Z=1\) versus \(Z=0\) is \(\exp(\gamma_r)\) at every time on that transition. This is a proportional-hazards assumption for the factor. It also produces an estimate and standard error for \(\gamma_r\), provided the data contain information to estimate it.

With factor stratification, each level of \(Z\) has its own unspecified baseline hazard for transition \(r\). Thus the hazard contrast between \(Z\) levels is not constrained to be constant over time. But the model does not estimate a coefficient or hazard ratio for \(Z\): the factor’s group-specific baseline hazards absorb those differences. Other covariate effects in the model are generally assumed common across the factor strata within that transition. If that assumption is not appropriate, interactions or stratum-specific coefficients require a different model.

Stratification does not mean that the factor has been ignored. It conditions the risk-set comparisons on its levels and can control for group-specific baseline patterns. It does mean that the analysis cannot directly report an adjusted hazard ratio for that factor from the stratified fit. If the factor is itself the primary exposure and its effect is the target, stratifying on it removes the comparison needed to estimate that effect.

Why the Partial Likelihood Changes

The distinction follows directly from the Cox partial likelihood. For a single event at time \(t\) on transition \(r\), let \(i\) be the individual who experiences the event and \(R_r(t)\) the individuals at risk for that transition just before \(t\). Assume initially that event times are distinct. In the factor-adjusted model, the conditional probability that \(i\) is the one to experience the event, given one event in that risk set, is

$$ \frac{\exp\{\gamma_r Z_i+\beta_r^\mathsf{T}W_i\}} {\sum_{k\in R_r(t)}\exp\{\gamma_r Z_k+\beta_r^\mathsf{T}W_k\}}. $$

The common baseline hazard \(\lambda^0_r(t)\) cancels from the numerator and denominator. Multiplying these event contributions over event times gives the transition-specific partial likelihood. The coefficient \(\gamma_r\) is learned from comparisons between factor levels within risk sets.

Under factor stratification, the event is compared only with individuals in the same factor level. Write \(R_{r,z}(t)=\{k\in R_r(t):Z_k=z\}\). The corresponding event contribution is

$$ \frac{\exp\{\beta_r^\mathsf{T}W_i\}} {\sum_{k\in R_{r,Z_i}(t)}\exp\{\beta_r^\mathsf{T}W_k\}}. $$

Here the group-specific baseline \(\lambda^0_{r,z}(t)\) cancels within the level-specific risk set. Since every individual in that risk set has the same \(Z\), there is no within-set contrast in \(Z\) from which to estimate \(\gamma_r\). This is the precise reason stratification controls for the factor but does not estimate its coefficient.

Justification: At an event time, the Cox model assigns each at-risk individual a hazard proportional to its relative-risk term. Dividing the event individual’s hazard by the sum of hazards in the relevant risk set removes the common baseline hazard. If the risk set is restricted to one factor level, the factor is constant there and contributes no estimable contrast; if the risk set mixes factor levels, its coefficient can be estimated under the proportional-hazards model.

Worked Example: Separate Baselines for Two Transitions

Worked Example: Separate Baselines for Two Transitions

Suppose a hypothetical illness-death model has transitions from healthy to ill (\(r_1\)) and from ill to dead (\(r_2\)). A binary exposure \(X\) has coefficient \(\log(2)=0.6931\) on both transitions, while the baseline hazards are \(0.030\) and \(0.012\) per person-year, respectively. Assume for this illustration that the proportional-hazards model is adequate and that the exposure effect is the same on both transitions.

For an unexposed individual, the transition hazards are \(0.030\) per person-year for healthy-to-ill and \(0.012\) per person-year for ill-to-dead. For an exposed individual, the fitted hazards are

$$ \lambda_{r_1}(t\mid X=1)=0.030\exp(0.6931)\approx 0.0600, \qquad \lambda_{r_2}(t\mid X=1)=0.012\exp(0.6931)\approx 0.0240. $$

The units remain transitions per person-year, and the exposure hazard ratio is \(2.00\) for each transition. Allowing separate transition baselines handles the different underlying transition rates; it does not, by itself, make the exposure effect transition-specific. If the exposure effects differ by transition, the coefficients must also be allowed to differ.

Worked Example: Estimate a Factor Effect or Stratify It

Worked Example: A Binary Factor in Four Risk Sets

Consider hypothetical data for one transition. At each of four distinct event times, the risk set contains two individuals: one with \(Z=0\) and one with \(Z=1\). One individual experiences the transition at each time. The event occurs to the \(Z=1\) individual at three times and to the \(Z=0\) individual once. Assume the risk sets are correctly defined, there are no tied event times, and the proportional-hazards model is reasonable for this illustration.

Under the adjusted model, each event contribution is \(\exp(\gamma Z_i)/[1+\exp(\gamma)]\). The partial likelihood is therefore

$$ L(\gamma)= \left\{\frac{\exp(\gamma)}{1+\exp(\gamma)}\right\}^{3} \left\{\frac{1}{1+\exp(\gamma)}\right\} =\frac{\exp(3\gamma)}{\{1+\exp(\gamma)\}^{4}}. $$

The log partial likelihood is \(\ell(\gamma)=3\gamma-4\log\{1+\exp(\gamma)\}\). Its derivative is \(3-4\exp(\gamma)/\{1+\exp(\gamma)\}\). Setting this equal to zero gives \(\exp(\hat\gamma)/\{1+\exp(\hat\gamma)\}=3/4\), so \(\exp(\hat\gamma)=3\) and \(\hat\gamma=\log(3)=1.099\). The fitted hazard ratio is 3.00 for \(Z=1\) versus \(Z=0\), under the proportional-hazards assumption. The estimate is highly uncertain with only four events; it should not be interpreted as precise evidence of a large effect.

If instead we stratify by \(Z\), each comparison set contains only one factor level. With the specified two-person risk sets, each level-specific risk set contains just one individual, so there is no within-stratum comparison for estimating another covariate effect either. More generally, a factor-stratified model can estimate effects of \(W\) when individuals with different \(W\) values are compared within \(Z\)-specific risk sets, but it cannot estimate the effect of \(Z\) itself.

Worked Example: When Stratification Avoids a Constant-Ratio Assumption

Worked Example: A Factor Effect That Changes Over Time

Suppose hypothetical estimated transition hazards for two levels of a factor are \(0.020\) and \(0.040\) per person-year early in follow-up, and \(0.060\) and \(0.090\) per person-year later. The corresponding hazard ratios for level 1 versus level 0 are

$$ \frac{0.040}{0.020}=2.00 \qquad\text{and}\qquad \frac{0.090}{0.060}=1.50. $$

These values do not support a constant hazard ratio over time. A single factor coefficient in a proportional-hazards model would impose one ratio, so that specification may be unsuitable. Stratifying on the factor allows its baseline transition hazards to follow different time patterns without imposing a constant ratio. This flexibility costs the ability to estimate a single factor hazard ratio. The numerical pattern alone is not conclusive evidence of nonproportionality: sparse events and sampling variability can produce changing estimates, so diagnostics and scientific context matter.

Practical Choice, Diagnostics, and Limitations

The choice should follow the scientific question and the plausible hazard structure. If the goal is to estimate a factor hazard ratio and a constant ratio is defensible, include the factor as a covariate. If the factor is needed to control markedly different baseline patterns, but its own effect is not the target, stratification can be appropriate. If both a factor effect and flexible baseline patterns are required, a simple Cox model cannot simultaneously give a free baseline for each factor level and estimate a separate coefficient for that same factor from those strata; another modeling strategy or a different estimand is needed.

In a multi-state analysis, make the choice transition by transition. A factor may have a proportional effect on one transition but a changing effect on another. Transition-specific coefficients or factor-by-transition interactions address differences in covariate effects across transitions; they are not the same as giving transitions separate baseline hazards. Likewise, stratifying by transition controls baseline differences between transitions but does not automatically control factor-related differences within each transition.

  • Check the target. If the factor’s hazard ratio is a required result, do not remove its cross-level contrast by stratifying on it.
  • Check proportionality when estimating a coefficient. Transition-specific Schoenfeld-residual diagnostics and plots of estimated effects over time can reveal patterns inconsistent with a constant hazard ratio. Such diagnostics are less informative when events are few.
  • Check within-stratum information. For factor-stratified analyses, covariate effects are identified by comparisons within the factor-specific risk sets. If those sets are small or show little covariate variation, estimates can be unstable or unavailable.
  • Check the number of factor levels and transitions. Many levels multiplied by many transitions create many baseline strata. Some strata may have few events, yielding limited information about other covariate effects and poorly determined baseline estimates.
  • Check the data structure and event handling. Risk sets must reflect who can experience each transition at each time. Tied events require a suitable tie-handling method; censoring assumptions and dependence from repeated transitions by the same individual also affect inference.

The main alternative is not simply “more” or “less” adjustment: it changes the model. A coefficient model is more parsimonious and gives a directly interpretable hazard ratio, but constrains that ratio over time. A stratified model is more flexible about the factor’s baseline hazard, but does not quantify its effect and usually needs adequate within-stratum information for the remaining coefficients. Neither approach alone establishes causal effects. Interpretation also depends on the covariates included, the risk-set construction, and the assumptions that support the model.

Common mistake: “I stratified by treatment group, so the model estimates and adjusts for the treatment hazard ratio.” The correction is that stratification permits separate treatment-group baseline hazards and prevents a treatment coefficient from being estimated in that model. To estimate a treatment hazard ratio, treatment levels must be compared in risk sets under an explicit effect model, such as a proportional-hazards coefficient.
Key takeaway: Transition stratification gives each transition its own baseline hazard. Factor adjustment estimates a factor effect under a specified proportional-hazards form. Factor stratification allows factor-specific baseline hazards but does not estimate the factor’s hazard ratio. State clearly which dimension is stratified and which effect is the target.

Check Your Understanding

Answer each question, then compare your reasoning with the solutions below.

  1. In a transition-specific Cox model, what does stratifying by transition allow that a common baseline does not?
  2. Why can a model with a separate baseline hazard for each level of a binary factor not estimate that factor’s coefficient from within-stratum comparisons?
  3. A fitted factor coefficient is \(0.4055\). What is the estimated hazard ratio, and what assumption gives it a constant interpretation over time?
  4. When might factor stratification be preferable to fitting one factor coefficient?
  5. Why does stratifying on the primary exposure prevent a direct estimate of its hazard ratio in that model?

Solutions. (1) It permits each transition to have its own baseline hazard function, rather than forcing a common baseline pattern across transitions. (2) The factor is constant within each factor-specific risk set, so it cancels from the conditional event probabilities and supplies no contrast for its coefficient. (3) \(\exp(0.4055)\approx1.50\); the proportional-hazards assumption makes this hazard ratio constant over time for the modeled transition, conditional on the other covariates. (4) It can be preferable when the factor’s baseline hazard patterns plausibly differ over time and a constant factor hazard ratio is not needed. (5) The stratified model compares individuals only within the exposure level, so its partial likelihood contains no cross-level exposure contrast from which to estimate that ratio.

Clinical Biostats