HealthEconomics.wiki — Knowledge infrastructure for health economicsDraft for review · v0.1.0

HealthEconomics.wiki · Interactive demonstrator

Transition Matrix Explorer

A transition matrix is the table of probabilities of moving between, or staying in, health states in one cycle of a Markov model, with rows summing to one. Build one, check it, push a cohort through it, and see why a shorter cycle needs a root of the whole matrix rather than a formula applied to each cell.

Source: Transition Matrix, HealthEconomics.wiki concept page, content version 1.0.3.

Work through the matrix in three steps

In a Markov model the transition matrix moves the cohort forward in time, so every cost and QALY the model reports rests on the state occupancy it produces. This explorer uses the three-state progressive cancer model from the concept page: progression-free (PF), progressed disease (PD) and Dead.

1 · StructureRows are the starting states, columns the end states, and every row sums to one.
2 · PropagateThe row vector of state proportions times the matrix gives the next cycle.
3 · ConvertA shorter cycle takes the nth root of the whole matrix, not of each cell.

Start with a matrix

Each scenario loads a matrix into step 1. The first is the page's worked example; the others are illustrative variations built to expose a specific error or boundary. None of the figures are clinical estimates.

1 · Build and check the matrixScenario: Canonical worked example

How are the cells entered?

From \ ToPFPDDeadRow total
PF
PD
Dead absorbing

Rows are the state at the start of a cycle; columns the state at its end. Cycle length: one year.

The model's transition structure is progressive: there is no return from PD to PF, so that cell is a structural zero. Death is absorbing, with 1 on the diagonal and 0 elsewhere in its row.

pij ≥ 0 for all i, j,    ∑j=1K pij = 1 for each i

Checks before the matrix enters the model

    2 · Propagate the cohortThe whole cohort starts progression-free: m0 = (1, 0, 0)

    Multiplying the row vector of state proportions by the matrix moves the cohort forward one cycle. Repeating the step builds the cohort trace. With a constant matrix the result after n cycles is a matrix power.

    mt+1 = mt Pt,    mn = m0 Pn  when Pt = P for every cycle
    3
    End of cyclePFPDDeadTotal

    P³: probabilities over the whole run

    Entries of Pn are n-cycle transition probabilities summed over every pathway, including those through intermediate states.

    How the latest cycle was calculated

    Counting costs and QALYs within each cycle, including half-cycle correction, belongs to cohort simulation and leaves the matrix unchanged, so it is not shown here.

    3 · Change the cycle lengthFrom the annual matrix in step 1 to a shorter cycle

    Converting each annual probability to a shorter-cycle probability on its own applies only to two-state models. Assuming the same shorter-cycle matrix applies throughout the year, the correct conversion takes the nth root of the whole matrix, which returns P when raised to the power n.

    P1/n = V D1/n V−1,    (P1/n)n = P

    Because this progressive matrix is upper triangular, its eigenvalues are its diagonal entries, so the root has a closed form: r11 = p111/n, r22 = p221/n, r12 = p12(r11 − r22)/(p11 − p22), and the death entries are the row remainders. For n = 2 this is the page's r12 = p12/(r11 + r22).

    Where the cohort is after 3 years

    Starting with everyone in PF. The annual model is the reference the shorter-cycle model should reproduce. Differences from it are shown under each value.

    Why the cell-by-cell formula fails

    Is there a valid rate matrix?

    The matrix logarithm of P, when it exists, gives a rate (generator) matrix Q with rows summing to zero. Dividing it by n and exponentiating gives the same root. If Q has a negative off-diagonal rate, P is not embeddable.

    Going further · Uncertainty with Dirichlet rowsSampling keeps every row valid; the root still needs checking each time

    In probabilistic sensitivity analysis the exits from a state are sampled together, usually from a Dirichlet distribution, so each sampled row still sums to one. Absorbing rows stay fixed and structural zeros stay zero. When the model runs on shorter cycles, the root has to be taken for each sampled matrix, not once for the mean, because whether it is valid depends on the sampled values.

    100

    Illustrative parameterisation: each row's Dirichlet parameters are the step 1 probabilities times the effective sample size. Fitting real parameters from counts is covered on the Dirichlet distribution page. Draws use a fixed seed sequence, so results can be reproduced.

    —sampled matrices with every row summing to one
    —sampled matrices whose six-month root has a negative entry
    —lowest root value of PF to Dead across draws

    Recognise the parts of a transition matrix

    What applies to the matrix as a whole sits here; single entries, survival curves and hazard ratios belong to the transition probability concept.

    Rows and columns

    A model with K mutually exclusive, collectively exhaustive states needs a K × K matrix for each cycle. Rows are starting states and columns end states, so each row accounts for everyone who starts in that state.

    Look for: a stated orientation. Some texts outside health economics put starting states in columns, which reverses the multiplication.

    The diagonal and absorbing states

    Diagonal entries are the probabilities of staying in a state for a cycle. An absorbing state, usually death, has 1 on the diagonal and 0 elsewhere in its row.

    Look for: a diagonal filled as a remainder; it can hide a negative value.

    Structural zeros

    Probabilities for disallowed transitions are zero. These zeros encode the model's transition structure, such as no recovery from a progressed cancer.

    Look for: zeros that stay zero through conversion and sampling, and a route to death from every living state.

    Constant or cycle-dependent matrices

    A model can use one matrix for every cycle (a time-homogeneous chain) or a different matrix P1, P2, … for each cycle, for example when age-specific mortality changes over simulation time.

    Look for: one constant matrix used where risk clearly changes with age or time.

    Tunnel states

    When risk depends on time already spent in a state, tunnel states change the shape of the matrix rather than its values. Each adds a row and a column, and its row sends the cohort onward rather than letting it stay.

    Look for: how much history the model needs; every tunnel state enlarges the matrix.

    Building from rates with competing exits

    When evidence gives rates, build a rate matrix Q and convert it in one step: P(Δ) = exp(ΔQ). Applying p = 1 − e−rt to each rate separately is wrong when a state has competing exits, because a person can have more than one event in a cycle.

    Look for: rates converted one at a time in a multistate model.

    The core rules

    Every entry lies between 0 and 1, every row sums to one, the cohort moves by mt+1 = mtPt, and a shorter cycle uses a root of the whole matrix that reproduces P when raised to the power n.

    Where transition matrices go wrong
    • Rows that do not sum to one within rounding tolerance; entries outside zero and one, including those produced by roots, logarithms or sampling.
    • Absorbing rows without 1 on the diagonal; disallowed transitions that are not zero; living states with no route to death.
    • Changing cycle length cell by cell. Row-sum checks miss this error, because every row of the incorrect matrix still sums to one.
    • Filling a row from separately sourced probabilities with the diagonal as the remainder, which can hide a negative diagonal or exits that describe different populations or intervals.
    • Using one constant matrix when risk changes with age or time in a state, which calls for cycle-specific matrices or tunnel states instead.

    Two further checks apply to a converted matrix or a long trace: a converted matrix raised to the right power should return the original, and proportions should add to one in every cycle. The ISPOR-SMDM report also suggests setting parameters so the trace can be predicted, for example so that no one enters a given state.

    Limits no check repairs

    The matrix describes average movement under the Markov property and carries no costs or utilities. A valid root need not be unique, and different roots can lead to different conclusions about cost-effectiveness. Coherent arithmetic does not show that the states and evidence describe the disease well enough for the decision.

    Not every matrix is diagonalisable, and a root may contain complex or negative entries. Necessary conditions for a valid rate matrix to exist include a positive determinant no greater than the product of the diagonal entries, and no zero entry for a transition that is reachable through other states. When a root is not stochastic, Chhatwal and colleagues approximate it with the closest stochastic matrix; that approximation is not implemented here.

    What two HTA bodies ask for

    PBAC (Australia) asks submissions to present every transition probability in the base case with point and interval estimates and justified sources, to adjust values to the model's cycle and structure, to explain the cycle length and to assess correlation between transition probabilities. Guidelines for preparing a submission to the PBAC, version 5.0 (2016), subsections 3A.2.3 and 3A.4.1.

    KCE (Belgium) asks for each state to be specified as temporary or absorbing, for transition probabilities to be presented, for example in matrix form, with an indication of whether each is constant or variable, and for the cycle length to be justified. Belgian guidelines for economic evaluations, third edition, KCE Reports 400C (2025), Guideline 14.

    Method, safeguards and limitations of this demonstrator

    All figures are illustrative and none are clinical estimates. The canonical scenario reproduces the worked example on the concept page; the other scenarios are teaching variations created for this demonstrator. The tool is limited to the three-state progressive structure with a constant annual matrix, so the matrix root uses the closed form for an upper-triangular matrix rather than a general eigendecomposition, and it reports the root with non-negative real diagonal entries. It does not model tunnel states, cycle-dependent matrices, half-cycle correction, costs or QALYs.

    The proportional split shown in step 3 divides a state's total shorter-cycle exit probability in proportion to its annual exits. It is appropriate for absorbing exits but not universal; the transition probability page discusses it. Dirichlet parameters in the uncertainty panel are scaled from point estimates purely to illustrate the sampling-loop check. This is an educational tool, not modelling software or medical advice.

    Sources cited on the concept page
    • Alarid-Escudero F, Krijkamp E, Enns EA, et al. A tutorial on time-dependent cohort state-transition models in R using a cost-effectiveness analysis example. Medical Decision Making. 2023;43(1):21-41. doi:10.1177/0272989X221121747
    • Briggs AH, Ades AE, Price MJ. Probabilistic sensitivity analysis for decision trees with multiple branches: use of the Dirichlet distribution in a Bayesian framework. Medical Decision Making. 2003;23(4):341-350. doi:10.1177/0272989X03255922
    • Chhatwal J, Jayasuriya S, Elbasha EH. Changing cycle lengths in state-transition models: challenges and solutions. Medical Decision Making. 2016;36(8):952-964. doi:10.1177/0272989X16656165
    • Jones E, Epstein D, García-Mochón L. A procedure for deriving formulas to convert transition rates to probabilities for multistate Markov models. Medical Decision Making. 2017;37(7):779-789. doi:10.1177/0272989X17696997
    • Siebert U, Alagoz O, Bayoumi AM, et al. State-transition modeling: a report of the ISPOR-SMDM Modeling Good Research Practices Task Force-3. Value in Health. 2012;15(6):812-820. doi:10.1016/j.jval.2012.06.014
    • Sonnenberg FA, Beck JR. Markov models in medical decision making: a practical guide. Medical Decision Making. 1993;13(4):322-338. doi:10.1177/0272989X9301300409