Solution (source code)

= Solution

The variance of an estimated hazard increment is large when its group has few individuals in the <risk set>. The <log-rank weights> are near zero when either $r_j^{(0)}$ or $r_j^{(1)}$ is small and are largest when both groups retain substantial information. They therefore suppress noisy late-event comparisons and weight each observed-minus-expected event by its available information. Unit weights would instead give equal influence to unstable increments from depleted risk sets.