# Kaplan–Meier estimator

The **Kaplan–Meier estimator**,^{[1]}^{[2]} also known as the **product limit estimator**, is a non-parametric statistic used to estimate the survival function from lifetime data. In medical research, it is often used to measure the fraction of patients living for a certain amount of time after treatment. In other fields, Kaplan–Meier estimators may be used to measure the length of time people remain unemployed after a job loss,^{[3]} the time-to-failure of machine parts, or how long fleshy fruits remain on plants before they are removed by frugivores. The estimator is named after Edward L. Kaplan and Paul Meier, who each submitted similar manuscripts to the *Journal of the American Statistical Association*. The journal editor, John Tukey, convinced them to combine their work into one paper, which has been cited about 34,000 times since its publication.^{[4]}

## Contents

## Basic concepts

A plot of the Kaplan–Meier estimator is a series of declining horizontal steps which, with a large enough sample size, approaches the true survival function for that population. The value of the survival function between successive distinct sampled observations ("clicks") is assumed to be constant.

An important advantage of the Kaplan–Meier curve is that the method can take into account some types of censored data, particularly *right-censoring*, which occurs if a patient withdraws from a study, is lost to follow-up, or is alive without event occurrence at last follow-up. On the plot, small vertical tick-marks indicate individual patients whose survival times have been right-censored. When no truncation or censoring occurs, the Kaplan–Meier curve is the complement of the empirical distribution function.

In medical statistics, a typical application might involve grouping patients into categories, for instance, those with Gene A profile and those with Gene B profile. In the graph, patients with Gene B die much more quickly than those with gene A. After two years, about 80% of the Gene A patients survive, but less than half of patients with Gene B.

In order to generate a Kaplan–Meier estimator, at least two pieces of data are required for each patient (or each subject): the status at last observation (event occurrence or right-censored) and the time to event (or time to censoring). If the survival functions between two or more groups are to be compared, then a third piece of data is required: the group assignment of each subject.^{[5]}

## Benefits and limitations

Survival analysis is the evaluation of how long individuals, who are endangered of certain health risk, will survive. Kaplan-Meier estimator is one of most frequently used survival analyses. It is based on a “time to event” model, meaning its endpoint is used to predict a time when certain positive events or negative events will occur. Benefits of the Kaplan-Meier are it estimates recovery rates, the probability of death, and the effectiveness of medications. It can also measure multiple variables to determine if there is a correlation between more than one of the events. Unfortunately, there are disadvantages to the Kaplan-Meier estimator. When estimating the outcomes of numerous variables, researchers risk censoring the data. Censored data is when the variables being tested do not accurately display a real life scenario for the patient or majority of participants. Another potential error is if a competing event were to rise. For example, if a doctor was using the Kaplan-Meier estimator to follow a patient with a malignant brain tumor and the patient were to die, the estimator could no longer be used. Overall, the Kaplan-Meier estimator provides more benefits than limitations, however, patients or participants involved should be notified of these potential errors. ^{[6]}

## Formulation

Let *S*(*t*) be the probability that a member from a given population will have a lifetime exceeding time, *t*. For a sample of size *N* from this population, let the observed times until death (or loss to follow-up) of the *N* sample members be

Corresponding to each *t*_{i} is *n*_{i}, the number "at risk" just prior to time *t*_{i}, and *d*_{i}, the number of deaths at time *t*_{i}.

Note that the intervals between events are typically not uniform. For example, a small data set might begin with 10 cases. Suppose subject 1 dies on day 3, subjects 2 and 3 die on day 11 and subject 4 is lost to follow-up (censored) at day 9. Data up to day 11 would be as follows.

1 |
3 | 1 | 10 |

2 |
11 | 2 | 8 |

The Kaplan–Meier estimator is the nonparametric maximum likelihood estimate of *S*(*t*), where the maximum is taken over the set of all piecewise constant survival curves with breakpoints at the event times *t*_{i}. It is a product of the form

When there is no censoring, *n*_{i} is just the number of survivors just prior to time *t*_{i}. With censoring, *n*_{i} is the number of survivors minus the number of losses (censored cases). It is only those surviving cases that are still being observed (have not yet been censored) that are "at risk" of an (observed) death.^{[7]}

There is an alternative definition that is sometimes used, namely

The two definitions differ only at the observed event times. The latter definition is right-continuous whereas the former definition is left-continuous.

Let *T* be the random variable that measures the time of failure and let *F*(*t*) be its cumulative distribution function. Note that

Consequently, the right-continuous definition of may be preferred in order to make the estimate compatible with a right-continuous estimate of *F*(*t*).

## Statistical considerations

The Kaplan–Meier estimator is a statistic, and several estimators are used to approximate its variance. One of the most common such estimators is Greenwood's formula:^{[8]}

In some cases, one may wish to compare different Kaplan–Meier curves. This may be done by several methods including:

## Implementations in statistics packages

- SAS: The Kaplan–Meier estimator is implemented in the
`proc lifetest`

procedure.^{[9]} - R: the Kaplan–Meier estimator is available as part of the
`survival`

package.^{[10]}^{[11]}^{[12]} - Stata: the command
`sts`

returns the Kaplan–Meier estimator.^{[13]} - Python: The
`lifelines`

package includes the Kaplan–Meier estimator^{[14]}

## See also

## References

- ↑
**Lua error in Module:Citation/CS1/Identifiers at line 47: attempt to index field 'wikibase' (a nil value).** - ↑ Kaplan, E.L. in a retrospective on the seminal paper in "This week's citation classic".
*Current Contents***24**, 14 (1983). Available from UPenn as PDF. - ↑
**Lua error in Module:Citation/CS1/Identifiers at line 47: attempt to index field 'wikibase' (a nil value).** - ↑ "Paul Meier, 1924–2011".
*Chicago Tribune*. August 18, 2011.<templatestyles src="Module:Citation/CS1/styles.css"></templatestyles> - ↑
**Lua error in Module:Citation/CS1/Identifiers at line 47: attempt to index field 'wikibase' (a nil value).** - ↑ Jager, K., Dijk, P., Zoccali, C., & Dekker, F. (2008). The analysis of survival data: The Kaplan–Meier method. Kidney Int Kidney International, 560-565. Retrieved December 9, 2015, from http://www.nature.com/ki/journal/v74/n5/full/ki2008217a.html
- ↑ Costella, John P. (2010). "A simple alternative to Kaplan–Meier for survival curves" (PDF).
*Unpublished*.<templatestyles src="Module:Citation/CS1/styles.css"></templatestyles> - ↑ Greenwood, M. (1926). "The natural duration of cancer".
*Reports on Public Health and Medical Subjects*. London: Her Majesty's Stationery Office.**33**: 1–26.<templatestyles src="Module:Citation/CS1/styles.css"></templatestyles> - ↑ The LIFETEST Procedure http://support.sas.com/documentation/cdl/en/statug/68162/HTML/default/viewer.htm#statug_lifetest_overview.htm
- ↑ "survival: Survival Analysis".
*R Project*.<templatestyles src="Module:Citation/CS1/styles.css"></templatestyles> - ↑
- ↑ Chen, Ding-Geng; Peace, Karl E. (2014).
*Clinical Trial Data Analysis Using R*. CRC Press. pp. 99–108.<templatestyles src="Module:Citation/CS1/styles.css"></templatestyles> - ↑ "sts — Generate, graph, list, and test the survivor and cumulative hazard functions" (PDF).
*Stata Manual*.<templatestyles src="Module:Citation/CS1/styles.css"></templatestyles> - ↑ "lifelines".<templatestyles src="Module:Citation/CS1/styles.css"></templatestyles>.

## Further reading

- Aalen, Odd; Borgan, Ornulf; Gjessing, Hakon (2008).
*Survival and Event History Analysis: A Process Point of View*. Springer. pp. 90–104. ISBN 978-0-387-68560-1.<templatestyles src="Module:Citation/CS1/styles.css"></templatestyles> - Greene, William H. (2012). "Nonparametric and Semiparametric Approaches".
*Econometric Analysis*(Seventh ed.). Prentice-Hall. pp. 909–912. ISBN 978-0-273-75356-8.<templatestyles src="Module:Citation/CS1/styles.css"></templatestyles> - Jones, Andrew M.; Rice, Nigel; D'Uva, Teresa Bago; Balia, Silvia (2013). "Duration Data".
*Applied Health Economics*. London: Routledge. pp. 139–181. ISBN 978-0-415-67682-3.<templatestyles src="Module:Citation/CS1/styles.css"></templatestyles>