Functions & Formulae

Each applied formula has its own function page, with a signature, implementations, and tests.

Population mean outcome of a cohort model run by stratum against one cohort at averaged inputs

k(w, q_1, q_2) = (L_strat, L_avg, gap_L)

Maps the shares of a starting population in two strata and the constant per-cycle death probability of each stratum to the population mean life expectancy found by running each stratum as its own cohort and weighting the results, to the life expectancy of one cohort run at the share-weighted mean probability, and to the gap between the two. HE-CF-COHM-001 carries the same comparison through a treatment that cuts each probability in proportion, to the QALY gains and ICERs of the article's worked example. TSD 15 states that a cohort run on average characteristics gives a biased estimate of the population mean where outcomes are non-linear in those characteristics, and the ISPOR-SMDM report states that outputs for a population-based starting cohort need one run for each stratum, aggregated across strata. Existing records are cited and not restated. The article's constant-risk life expectancy, 1/q minus one half, is the one-state case of HE-FM-ABS-001, whose 1/q cycles equal the mean geometric stay L_j of HE-FM-MKCH-002 and D_mean of HE-FM-MKA-004 with cycles of one year, less the half cycle that HE-ER-ABS-002 and HE-CF-MKCH-001 subtract for a cohort counted at the start of each cycle. The life years one stratum gains from a treatment are the difference of two values of that life expectancy, the ICER of the resulting QALY gain is HE-FM-ICER-001, and a proportional cut e gives the intervention risk of HE-FM-ARR-002 with a relative risk of 1 minus e, so none of these is restated. The share-weighted population effect is HE-FM-ATE-001, the value of deciding by subgroup is HE-FM-ATE-004, and HE-ER-CHN-002 shows why subgroup ICERs are not averaged. The cohort update and trace totals are HE-FM-MM-001, HE-FN-CSIM-001, HE-FM-CSIM-001 and HE-CF-CSIM-001, the second-order approximation to the mean of a curved output is HE-FM-EV-002, the background hazard of a mixed-sex cohort is HE-FM-BGM-003 with the error of reading a hazard at the mean age in HE-ER-BGM-007, and continuous-time life expectancy at constant rates is HE-FM-CONT-002. Notation follows the Cohort Model article.

  • Averaged-cohort gap in constant-risk life expectancy for two strata

    q_bar = w * q_1 + (1 - w) * q_2; L_strat = w * (1 / q_1 - 0.5) + (1 - w) * (1 / q_2 - 0.5); L_avg = 1 / q_bar - 0.5; gap_L = L_strat - L_avg

    Gives the population mean life expectancy when each of two strata with constant per-cycle death probabilities q_1 and q_2 is run as its own cohort and weighted by its share, the life expectancy of one cohort run at the share-weighted mean probability, and the difference between them. Each stratum result is the article's L(q), 1/q minus one half, the one-state case of HE-FM-ABS-001 with the half-cycle subtraction of HE-CF-MKCH-001, and the weighting is that of HE-FM-ATE-001. The half cycle cancels in gap_L, which equals w(1 minus w)(q_1 minus q_2) squared divided by q_1 q_2 q_bar (derived here), so the gap is never negative and is zero only when the strata share one probability or one stratum holds the whole cohort. The averaged cohort therefore never overstates life expectancy in this model and understates it whenever both strata are present with different probabilities, the bias that TSD 15 section 3.1 describes for an outcome that is non-linear in a patient characteristic; HE-FM-EV-002 approximates the same gap by a second-order term, whereas this form is exact.