Two Methods, Two Different Questions
When treatment effects change over time, a single summary can hide important features of the survival curves. A treatment might have little effect early and a benefit later, or it might help at first and then lose that advantage. The restricted mean survival time (RMST) difference and a weighted logrank test can both be useful in these settings, but they do not answer the same question.
An RMST contrast summarizes the difference in expected event-free time accumulated up to a specified horizon. A weighted logrank test instead compares observed and expected event counts over follow-up, with chosen weights determining which event times contribute more to its test statistic. The RMST contrast is a time-scale effect summary; the weighted logrank statistic is evidence against a null hypothesis, not generally an estimate of a single clinically interpretable treatment effect.
The comparison assumes a well-defined time-to-event outcome, randomized treatment assignment (or an appropriate basis for exchangeability), and adequate follow-up to estimate survival through the chosen horizon. Censoring must be independent of the event time within treatment groups, either unconditionally or conditional on variables accounted for in the analysis. The examples use hypothetical data and simplified calculations. In applications, the analysis should also respect the trial’s sampling design and prespecified analysis plan.
What the RMST Contrast Summarizes
The horizon \(\tau\) is part of the estimand: changing it can change the contrast. RMST does not require the treatment and control hazards to be proportional. It summarizes the area between the two survival curves from time zero through \(\tau\), retaining both the direction and duration of differences in survival.
The area interpretation follows from the tail-integral identity. For any nonnegative event time \(T\), the truncated time \(\min(T,\tau)\) can be written as the integral from zero to \(\tau\) of the indicator that \(T\) exceeds \(t\). Taking expectations gives:
Applying this identity to each group and subtracting gives \(\Delta(\tau)\). Thus, the contrast is a difference in expected event-free time restricted to the stated horizon—not a difference in median survival, a hazard ratio, or an unrestricted lifetime mean.
Worked Example: A Delayed Benefit and the RMST Difference
Suppose hypothetical survival curves are specified as piecewise linear through the following points, with time in years. Treatment and control survival are equal through year 2; the treatment curve is then higher. Calculate the RMST difference through \(\tau=6\).
For control, the survival values at times 0, 2, 4, and 6 are 1.00, 0.80, 0.60, and 0.40. For treatment, they are 1.00, 0.80, 0.70, and 0.55. Under the stated piecewise-linear assumption, the area on each two-year segment is its width multiplied by the average of its endpoint heights.
For control, the three segment areas are \(2(1.00+0.80)/2=1.80\), \(2(0.80+0.60)/2=1.40\), and \(2(0.60+0.40)/2=1.00\) years. Therefore \(\mu_0(6)=1.80+1.40+1.00=4.20\) years.
For treatment, the corresponding areas are \(2(1.00+0.80)/2=1.80\), \(2(0.80+0.70)/2=1.50\), and \(2(0.70+0.55)/2=1.25\) years. Thus \(\mu_1(6)=1.80+1.50+1.25=4.55\) years, and \(\Delta(6)=4.55-4.20=0.350\) years.
Under these hypothetical curves, treatment has 0.350 years more expected event-free time through year 6—about 4.20 months. This is a descriptive contrast for the chosen horizon. The calculation relies on the specified linear interpolation; estimated Kaplan–Meier curves are step functions and their RMST is obtained by integrating those steps, not by assuming linear segments between observed points.
What a Weighted Logrank Test Summarizes
At each event time, a logrank score compares the number of treatment-group events observed with the number expected if the groups had the same event hazard at that time. A weighted logrank test multiplies these event-time contributions by a weight \(w(t)\). Early-weighted, late-weighted, or other prespecified choices emphasize different parts of follow-up. The weight changes the test’s sensitivity; it does not turn the resulting statistic into an RMST difference.
For a tied event time \(t_j\), let \(Y_{1j}\) and \(Y_{0j}\) be the numbers at risk just before \(t_j\), \(d_{1j}\) and \(d_{0j}\) the numbers of events, \(Y_j=Y_{1j}+Y_{0j}\), and \(d_j=d_{1j}+d_{0j}\). A common weighted logrank score and its null variance estimate are:
The score is oriented so that a negative value indicates fewer treatment events than expected under equal hazards, which is in the direction of treatment benefit. For a prespecified weight and adequate event information, a large-sample test uses \(Z=U_w/\sqrt{\widehat{\operatorname{Var}}_0(U_w)}\) and compares it with the standard normal distribution under the null. A two-sided p-value assesses compatibility with the null of equal survival experience, as calibrated by the test; it is not the probability that the null is true.
The variance expression above is the usual large-sample form for tied event groups. Its use relies on the standard logrank conditions, including appropriate independent censoring and a valid risk-set comparison. In particular, censoring must not selectively remove people with different future event risks in a way that invalidates the comparison. If ties are extensive or a particular implementation uses a tie correction, its stated variance convention should be followed consistently.
Worked Example: A Late-Weighted Test Under a Delayed Effect
Consider a hypothetical randomized trial with three event-time blocks. The selected prespecified weights are 1, 1, and 2, so the final block receives more emphasis. Calculate the score, its estimated null variance, and the approximate two-sided p-value.
| Block | \(Y_1\) | \(Y_0\) | \(d_1\) | \(d_0\) | Weight |
|---|---|---|---|---|---|
| 1 | 100 | 100 | 10 | 10 | 1 |
| 2 | 90 | 90 | 9 | 9 | 1 |
| 3 | 81 | 81 | 4 | 16 | 2 |
In block 1, \(d_1-(Y_1/Y)d=10-(100/200)(20)=0\), and the variance contribution is \(1^2(100)(100)(20)/(200^2)=5.00\). In block 2, the score contribution is \(9-(90/180)(18)=0\), and the variance contribution is \(1^2(90)(90)(18)/(180^2)=4.50\).
In block 3, the unweighted score contribution is \(4-(81/162)(20)=4-10=-6\). After weighting, it is \(2(-6)=-12\). The variance contribution is \(2^2(81)(81)(20)/(162^2)=20.0\). Consequently, \(U_w=0+0-12=-12.0\), and \(\widehat{\operatorname{Var}}_0(U_w)=5.00+4.50+20.0=29.5\).
The standard error is \(\sqrt{29.5}=5.431\), so \(Z=-12.0/5.431=-2.209\). Using a standard normal approximation, the two-sided p-value is approximately 0.0272. Under this approximation, the data provide evidence against equal survival experience, in the direction of fewer treatment events in the late block. This is not an estimate of how many additional months of event-free time treatment provides. The calculation assumes the displayed weights were chosen in advance and treats the event blocks using the stated tied-event variance.
Why the Methods Can Disagree
A weighted logrank test is designed to accumulate evidence in event-time regions emphasized by its weights. Under local departures from equal hazards, its expected score is approximately driven by a weighted accumulation of hazard differences across the risk sets. In contrast, an RMST difference accumulates survival differences over time without an analyst-chosen event-time weight. A hazard difference and a survival difference are related, but they are not interchangeable: survival reflects the accumulated history of hazards.
This distinction matters especially when effects are delayed or cross. A late-weighted test can be sensitive to a benefit that begins late, while an early-weighted test can give relatively little influence to that benefit. With crossing effects, a weighted score may be positive or negative depending on the timing, size, and risk-set contribution of the opposing effects. The RMST difference also reflects both directions of the survival-curve difference, but its net value depends on the areas and the selected horizon. Neither method is guaranteed to declare a benefit simply because one portion of follow-up favors treatment.
Worked Example: Crossing Curves and a Net RMST Contrast
Suppose hypothetical treatment and control survival curves are piecewise linear through times 0, 2, 4, and 6 years. The treatment values are 1.00, 0.82, 0.60, and 0.42; the control values are 1.00, 0.78, 0.65, and 0.45. The curves favor treatment at year 2 but favor control at years 4 and 6. Find the RMST difference through year 6.
The survival differences \(S_1(t)-S_0(t)\) at the four points are 0, 0.04, -0.05, and -0.03. The area between the curves over years 0–2 is \(2(0+0.04)/2=0.040\) years. Over years 2–4 it is \(2(0.04-0.05)/2=-0.010\) years. Over years 4–6 it is \(2(-0.05-0.03)/2=-0.080\) years.
Adding these signed areas gives \(\Delta(6)=0.040-0.010-0.080=-0.050\) years. The treatment group therefore has 0.050 years less expected event-free time through year 6 under these curves, equivalent to about 0.60 months less. This net contrast does not mean treatment was worse at every time: the curves cross, and the early positive area is outweighed by later negative area.
A weighted logrank test on the same underlying trial could emphasize early or late event times and therefore yield different score directions or strengths. The survival values alone are not enough to calculate that test: event counts, risk sets, censoring information, and the chosen weights are also needed. This example demonstrates why the RMST contrast and the weighted test should not be treated as two numerical versions of the same quantity.
Choosing and Checking an Analysis
The choice should follow the scientific question. If the goal is to quantify the difference in event-free time accumulated by a clinically meaningful horizon, report an RMST contrast, its uncertainty, and the horizon. If the goal is a test with enhanced sensitivity to a prespecified pattern of event-time effects, a weighted logrank test may be appropriate. Reporting both can be informative when the estimand and test are clearly distinguished and both analyses were planned or transparently identified as supplementary.
The ordinary logrank test is a special case with constant weights and is a natural comparison when effects are roughly proportional over time. A delayed-effect weight can focus more strongly on later events; other weight choices can target other patterns. The RMST approach avoids selecting an event-time weight but requires choosing and justifying \(\tau\). A Cox-model hazard ratio offers a different summary, typically a single relative hazard measure; if hazards vary over time, a single number may not represent the time pattern well. None of these approaches makes a poorly chosen horizon, weight, or censoring assumption harmless.
Useful checks include plotting the estimated survival curves with numbers at risk, examining whether the apparent timing and direction of differences agree with the prespecified analysis, and checking how much information remains near \(\tau\). For a weighted logrank analysis, confirm the weight definition, the sign convention, and whether the observed score is driven by the time region the weight was meant to emphasize. For an RMST analysis, inspect whether the selected horizon is supported by adequate follow-up in both groups. These checks can reveal instability; they do not justify changing the analysis after seeing results and then treating the changed analysis as prespecified.
Check Your Understanding
Answer each question, then compare with the solutions below.
- If \(\Delta(5)=0.20\) years, what does this contrast mean, and what does it not mean?
- In a weighted logrank score, what does a negative value indicate under the sign convention used here?
- Why can an early-weighted and a late-weighted logrank test give different results under a delayed treatment effect?
- For survival-curve differences at times 0, 2, and 4 of 0, 0.06, and -0.02, calculate the signed area through year 4 assuming piecewise-linear curves.
- Name one key diagnostic for RMST and one for a weighted logrank analysis.
Solutions. (1) Through year 5, treatment has 0.20 years more expected event-free time than control; it is not a claim about median survival, a hazard ratio, or time gained after year 5. (2) Fewer treatment events than expected under equal hazards, in the direction of treatment benefit. (3) Their weights assign different influence to event-time regions, and a delayed effect contributes more to a late-weighted score. (4) The first area is \(2(0+0.06)/2=0.06\) years; the second is \(2(0.06-0.02)/2=0.04\) years; total area is 0.10 years. (5) For RMST, check that follow-up supports the chosen horizon in both groups; for a weighted logrank test, check that the weight and the event-time contributions match the prespecified effect pattern.