Nelson-Aalen Estimator

The Nelson-Aalen estimator is a nonparametric estimator of the cumulative hazard function.

The estimate is given by

\[\hat{H}(t) = \sum_{i: t_i < t} \frac{d_i}{n_i}\]

where $d_i$ is the number of observed events at time $t_i$ and $n_i$ is the number of subjects at risk for the event just before time $t_i$.

The pointwise standard error of the log of the survivor function can be computed directly as the standard error or a Bernoulli random variable with $d_i$ successes from $n_i$ samples:

\[\text{SE}(\hat{H}(t)) = \sqrt{\sum_{i: t_i < t} \frac{d_i(n_i-d_i)}{n_i^3}}\]



An immutable type containing cumulative hazard function estimates computed using the Nelson-Aalen method. The type has the following fields:

  • times: Distinct event times
  • nevents: Number of observed events at each time
  • ncensor: Number of right censored events at each time
  • natrisk: Size of the risk set at each time
  • chaz: Estimate of the cumulative hazard at each time
  • stderr: Standard error of the cumulative hazard

Use fit(NelsonAalen, ...) to compute the estimates and construct this type.

fit(NelsonAalen, times, status) -> NelsonAalen

Given a vector of times to events and a corresponding vector of indicators that dictate whether each time is an observed event or is right censored, compute the Nelson-Aalen estimate of the cumulative hazard rate function.

confint(na::NelsonAalen, α=0.05)

Compute the pointwise confidence intervals for the cumulative hazard function as a vector of tuples.