Tutorials › Competing Risks and Multi-State Models › Updating A Transition Matrix At One Event Time

Transition Intensities and Probabilities · Tutorial 287 of 699

Updating A Transition Matrix At One Event Time

Learn how to turn transition counts and origin-state risk sets at one event time into a row-stochastic transition-matrix update.

Advanced 10 min read

What You'll Learn

  • Define the event-time transition counts and origin-state risk sets used in the update.
  • Calculate each off-diagonal matrix entry from its transition count and origin-state risk set.
  • Obtain each diagonal entry by subtracting all outgoing increments from one.
  • Check that the resulting matrix has nonnegative entries and rows summing to one.
  • Distinguish an event-time matrix factor from an instantaneous transition intensity.
  • Identify when ties, empty risk sets, or incorrect denominators invalidate a calculation.

From Transition Counts to One Matrix Update

A transition matrix update at an event time translates observed transitions into changes in the probability of occupying each state. Its ingredients are local: for each origin state, count the observed transitions out of that state and divide by the number of individuals at risk in it immediately before the event time. The resulting off-diagonal entries describe transitions to other states; the diagonal entry accounts for remaining in the origin state at that update.

This is a single-time calculation, not a complete estimate of transition probabilities over an interval. It is also distinct from an instantaneous transition intensity: the update uses the estimated cumulative transition-hazard increments at that event time. The earlier material on transition-intensity matrices establishes the convention used here: rows index origin states, columns index destination states, and diagonal increments are negative sums of outgoing increments.

Definition: Consider \(K\) states, indexed by \(i,j\in\{1,\ldots,K\}\). At event time \(t\), let \(Y_i(t)\) be the number of individuals in state \(i\) and under observation immediately before \(t\). For \(i\ne j\), let \(dN_{ij}(t)\) be the number of observed transitions from state \(i\) to state \(j\) at \(t\). When \(Y_i(t)>0\), define the estimated off-diagonal increment by \(d\widehat A_{ij}(t)=dN_{ij}(t)/Y_i(t)\). Set \(d\widehat A_{ii}(t)=-\sum_{j\ne i}d\widehat A_{ij}(t)\). The single-event-time matrix factor is \(B(t)=I+d\widehat A(t)\), where \(I\) is the \(K\times K\) identity matrix.

Thus, for \(i\ne j\), \(B_{ij}(t)=dN_{ij}(t)/Y_i(t)\), while \(B_{ii}(t)=1-\sum_{j\ne i}dN_{ij}(t)/Y_i(t)\). A row of \(B(t)\) is computed using the risk set for that row's origin state. It is not computed using the total study sample or the risk set in a destination state.

For a row-vector convention, a current transition-probability matrix \(P(s,t-)\), whose entries describe transition probabilities up to just before \(t\), is updated at this event time by \(P(s,t)=P(s,t-)B(t)\). The focus here is how to calculate \(B(t)\), not how to combine all event-time factors across a follow-up period.

Why the Diagonal Is Determined by the Off-Diagonals

The observed transition counts directly determine the estimated increments for transitions between distinct states. The diagonal increment is not a separate count of transitions from a state back to itself. Instead, it is defined to make the total increment in each row zero. Adding the identity matrix then makes each row of the event-time factor sum to one.

$$ \sum_{j=1}^{K} d\widehat A_{ij}(t) = \sum_{j\ne i} d\widehat A_{ij}(t) - \sum_{j\ne i} d\widehat A_{ij}(t) =0, \qquad \sum_{j=1}^{K}B_{ij}(t)=1. $$

The diagonal factor entry is therefore the fraction of the origin-state risk set not assigned to an observed outgoing transition at that time. Under the usual single-transition-per-individual-at-a-time setup, the total number of outgoing transitions from state \(i\) at \(t\) cannot exceed \(Y_i(t)\). Consequently, \(B_{ii}(t)\ge 0\). Together with nonnegative off-diagonal entries, this makes \(B(t)\) a row-stochastic matrix: its entries are nonnegative and each row sums to one.

This check is useful, but it does not validate the data or assumptions by itself. A negative diagonal entry can signal a wrong denominator, duplicated counts, or an incompatible treatment of tied transitions. A row sum different from one usually signals an arithmetic or indexing error.

Worked Example: One Transition From a Single Origin State

Suppose a hypothetical two-state study has states 1 and 2. At time \(t\), 20 individuals are observed in state 1 immediately before \(t\), and 3 make the transition \(1\to2\). There are no transitions from state 2 at this time, and 8 individuals are at risk in state 2. Assume each individual can make at most one transition at \(t\), the state labels and event times are recorded correctly, and censoring before \(t\) has already been reflected in the risk sets.

The off-diagonal increment for \(1\to2\) is \(3/20=0.15\). There are no other outgoing transitions from state 1, so its diagonal entry is \(1-0.15=0.85\). For state 2, the outgoing count is zero, so its off-diagonal increment is 0 and its diagonal entry is 1.

$$ B(t)= \begin{pmatrix} 1-\frac{3}{20} & \frac{3}{20}\\ 0 & 1 \end{pmatrix} = \begin{pmatrix} 0.85 & 0.15\\ 0 & 1 \end{pmatrix}. $$

The first row says that the event-time factor assigns 0.15 to a transition from state 1 to state 2 and 0.85 to remaining in state 1 at this update. The second row is unchanged because no transition out of state 2 was observed. The entries are dimensionless probabilities, not rates per unit time.

Multiple Destinations and Multiple Origin States

When several transition types leave the same origin state at \(t\), calculate each off-diagonal entry separately with the same origin-state risk set. Then add those entries to obtain the total outgoing increment and subtract that total from one for the diagonal. Counts from different origin states use their respective risk sets, even when the transitions share the same event time.

Worked Example: Two Origin States at the Same Recorded Time

In a hypothetical three-state setting, state 1 has \(Y_1(t)=24\) individuals at risk just before \(t\). At \(t\), 2 transition from state 1 to state 2 and 1 transition from state 1 to state 3. State 2 has \(Y_2(t)=10\), with 1 transition to state 3. State 3 has \(Y_3(t)=6\), with no observed outgoing transition. Assume correct state and event-time recording, valid pre-event risk sets, and no individual makes more than one transition at \(t\).

For row 1, the two off-diagonal entries are \(2/24=0.08333\) and \(1/24=0.04167\). Their sum is \(3/24=0.125\), so \(B_{11}(t)=1-0.125=0.875\). For row 2, \(B_{23}(t)=1/10=0.10\), and \(B_{22}(t)=1-0.10=0.90\). Row 3 has no outgoing transitions, so \(B_{33}(t)=1\).

$$ B(t)= \begin{pmatrix} 0.875 & 0.08333 & 0.04167\\ 0 & 0.90 & 0.10\\ 0 & 0 & 1 \end{pmatrix}. $$

Each row sums to one: \(0.875+0.08333+0.04167=1\), \(0.90+0.10=1\), and \(1=1\). The first row's denominator is 24 for both outgoing transition types because both originate in state 1. The transition from state 2 instead uses the state 2 risk set of 10.

The update can be justified directly from the estimated transition-hazard increments. For each allowed transition \(i\to j\), the Nelson–Aalen increment at \(t\) is the observed count divided by the origin-state risk set. The transition-intensity matrix has that increment off the diagonal and the negative sum of outgoing increments on the diagonal. Adding the identity gives the event-time factor. This construction both retains the observed transition increments and produces rows that sum to one.

$$ B_{ij}(t)= \begin{cases} \dfrac{dN_{ij}(t)}{Y_i(t)}, & i\ne j,\ Y_i(t)>0,\\[6pt] 1-\displaystyle\sum_{k\ne i}\dfrac{dN_{ik}(t)}{Y_i(t)}, & i=j,\ Y_i(t)>0. \end{cases} $$

The formula is defined only for an origin state with a positive risk set if an outgoing count needs to be converted to an increment. If \(Y_i(t)=0\), there should be no observed transition out of state \(i\) at \(t\) under the stated risk-set definition. The event-time factor for that row is conventionally left as the identity row, since the data provide no at-risk individuals from which to estimate an outgoing increment. This is a boundary convention, not evidence that the true transition intensity is zero.

Worked Example: Competing Outgoing Transitions

Suppose, hypothetically, that state 1 represents being alive without a complication, while states 2 and 3 represent two distinct exit types. At a particular time, \(Y_1(t)=40\); 3 individuals transition from state 1 to state 2 and 5 transition from state 1 to state 3. Assume these are mutually exclusive observed transitions at that time, each individual is counted once in the state 1 risk set, and all eight events are correctly classified.

The two off-diagonal entries are \(3/40=0.075\) and \(5/40=0.125\). Their sum is \(8/40=0.20\), so the diagonal entry is \(1-0.20=0.80\). If states 2 and 3 have no observed outgoing transitions at \(t\), their rows are identity rows.

$$ B(t)= \begin{pmatrix} 0.80 & 0.075 & 0.125\\ 0 & 1 & 0\\ 0 & 0 & 1 \end{pmatrix}. $$

The state 1 row allocates the observed outgoing fraction across the two destinations; it does not treat the two destination-specific proportions as separate updates to be applied one after another. Applying separate sequential factors would make the result depend on an arbitrary ordering and would generally change the entries. The displayed factor is the single-time update based on the counts and common origin-state risk set.

Assumptions, Diagnostics, and Common Errors

The arithmetic requires a correctly specified state system, counts classified by both origin and destination, and risk sets measured immediately before the event time. For interpreting the increments as estimates of transition hazards in a population, the observation process must also be handled appropriately: in particular, censoring must be non-informative for the transition process, at least conditional on variables used in the analysis. The data must support the transition-counting setup, including the stated handling of event times and the rule that an individual cannot contribute multiple incompatible outgoing transitions from one origin at the same instant.

  • Check the denominator. \(Y_i(t)\) counts individuals at risk in origin state \(i\), not all participants and not those in the destination state.
  • Check the row total. Each row should sum to one, up to rounding. Its diagonal is one minus the sum of the outgoing off-diagonals.
  • Check nonnegativity. A negative diagonal under the usual setup suggests that the outgoing counts exceed the risk set or have been mishandled.
  • Check zero risk sets. Do not divide by zero. Investigate any claimed transition from an origin state with no one at risk.
  • Check the meaning of ties. Multiple individuals can have transitions recorded at the same time. If event-time ties create a more complicated within-time ordering or simultaneous-transition issue, the simple single-factor calculation may not resolve it.

A common mistake is to calculate a separate diagonal as \(1-dN_{ij}(t)/Y_i(t)\) for each destination \(j\), then place all of those values on the same diagonal. That ignores the other outgoing transitions from the origin state. With two destinations, the correct diagonal is \(1-\{dN_{ij}(t)+dN_{ik}(t)\}/Y_i(t)\), so the entire row sums to one. Another error is to use a different denominator for each destination. All outgoing transitions from the same origin at \(t\) use the same \(Y_i(t)\).

This event-time factor is not the only way to represent transition behavior. Transition intensities describe instantaneous rates and have units of inverse time; their increments are accumulated over time to build event-time factors. A constant-intensity model instead represents behavior over an interval through its assumed rate structure. Those approaches answer related but distinct questions and require their own assumptions. The count-over-risk-set factor is a nonparametric, event-time update; it does not smooth across time, repair informative censoring, or determine what happens inside a complex tied event time.

Key takeaway: At one event time, each off-diagonal entry is its origin-specific transition count divided by the origin-state risk set. The diagonal is one minus the sum of all outgoing entries in that row. Verify the denominator, row sum, nonnegativity, and event-time interpretation before using the factor.

Check Your Understanding

Work each problem using origin-state risk sets measured just before the stated time. Solutions follow the questions.

  1. In a two-state model, \(Y_1(t)=16\) and 4 individuals transition from state 1 to state 2. No transitions leave state 2. What is \(B(t)\)?
  2. In a three-state model, \(Y_1(t)=30\), with 3 transitions \(1\to2\) and 2 transitions \(1\to3\). Find the state 1 row of \(B(t)\).
  3. For the counts in Question 2, someone uses 30 as the denominator for transitions out of state 2, even though \(Y_2(t)=12\). What is wrong with this calculation?
  4. If a state has risk set zero and no observed outgoing transitions, should its outgoing increment be calculated by dividing zero by zero? Explain the convention.

Solutions. (1) \(B_{12}(t)=4/16=0.25\) and \(B_{11}(t)=1-0.25=0.75\). With no transitions out of state 2, its row is \((0,1)\), so \(B(t)=\begin{pmatrix}0.75&0.25\\0&1\end{pmatrix}\). (2) \(B_{12}(t)=3/30=0.10\), \(B_{13}(t)=2/30=0.06667\), and \(B_{11}(t)=1-0.10-0.06667=0.8333\). The row is \((0.8333,0.10,0.06667)\), which sums to one. (3) Each transition count is divided by the risk set in its own origin state. Transitions out of state 2 use \(Y_2(t)=12\), not \(Y_1(t)=30\). (4) No: division by zero is undefined. With no one at risk, there is no information to estimate an outgoing increment, so the row is conventionally left unchanged as an identity row; this does not establish that the underlying transition intensity is zero.

Clinical Biostats