Survival analysis studies the time until an event occurs, such as failure, relapse, death, graduation, or customer churn. This reference helps students organize the special notation and assumptions used when outcomes are times rather than simple measurements. It is especially useful because many observations are censored, meaning the exact event time is not fully observed.
The cheat sheet connects basic time-to-event quantities with estimation, group comparison, and regression modeling.
Key Facts
- The survival function is , the probability that the event time is greater than time .
- The cumulative distribution function is for an event time .
- The hazard function is , the instantaneous event rate among those still at risk.
- The cumulative hazard is , and it relates to survival by .
- The Kaplan-Meier estimator is , where events occur among subjects at risk at time .
- Right censoring occurs when a subject is known to survive beyond a time , so the observed data are and .
- The log-rank test compares groups using observed and expected event counts, often summarized by for two groups.
- The Cox proportional hazards model is , and a one-unit increase in multiplies the hazard by .
Vocabulary
- Event time
- The event time is the time from a defined starting point until the event of interest occurs.
- Censoring
- Censoring occurs when the exact event time is unknown but partial information about is still available.
- Survival function
- The survival function gives the probability that a subject has not experienced the event by time .
- Hazard function
- The hazard function describes the instantaneous risk of the event at time among subjects still at risk.
- Kaplan-Meier estimator
- The Kaplan-Meier estimator is a step function estimate of survival that updates only at observed event times.
- Hazard ratio
- A hazard ratio compares hazards between groups or covariate levels, with in a Cox model.
Common Mistakes to Avoid
- Treating censored observations as event-free forever is wrong because censoring only tells us the event was not observed before the censoring time.
- Interpreting as the probability that the event has happened by time is wrong because is the probability of surviving past .
- Using ordinary linear regression on survival times is often wrong because censored outcomes violate the assumption that every response value is fully observed.
- Calling a hazard ratio a probability ratio is wrong because the hazard is an instantaneous event rate, not a direct probability over a fixed interval.
- Assuming Kaplan-Meier curves drop at censoring times is wrong because censoring reduces the risk set but does not directly create an event.
Practice Questions
- 1 At time , there are subjects at risk and events. If the previous Kaplan-Meier estimate is , compute .
- 2 In a Cox model, a treatment coefficient is . Compute the hazard ratio and interpret whether the treatment increases or decreases hazard.
- 3 Suppose . What is , the probability that the event has occurred by time ?
- 4 Explain why censoring can be included in Kaplan-Meier estimation but should not be treated the same as an observed event.
Understanding Survival Analysis Reference
A survival data set usually has one row for each person, machine, animal, or account. The row records a follow-up time and an indicator showing whether the event was seen. A person who leaves a study early still contributes useful information up to the departure time.
They were event-free during that observed period. This is why survival analysis does not simply remove incomplete records. Removing them can make long survival look less common than it really is.
The main requirement is independent censoring. In plain terms, after accounting for measured information, the reason observation ends should not reveal an unobserved event time. This assumption deserves careful thought in every study.
Kaplan-Meier estimates change only when events occur. At each event time, the method examines the risk set, meaning everyone who has not yet had the event and has not been censored earlier. It calculates the fraction who remain event-free at that moment, then multiplies that fraction into the earlier estimate.
Censored cases reduce the risk set after their censoring time, but they do not create a downward step. A graph can look precise near the beginning because many subjects are being followed.
Near the end, few subjects may remain at risk, so the curve is uncertain even when it appears smooth. Students should always inspect the numbers at risk below a survival plot and the confidence intervals around it.
Comparing two curves requires more than noticing which line is higher. The log-rank test combines information from each event time. It asks whether each group has about as many events as expected from its share of the people at risk.
It works best when the group difference is fairly consistent over time. Curves that cross can signal a changing treatment effect, different early and late risks, or random variation. In that situation, a single test result can hide an important pattern.
A non-significant result does not prove that groups have identical outcomes. It may reflect a small sample, few events, short follow-up, or large uncertainty.
The Cox model studies how several predictors relate to event risk at the same time. Its coefficients are usually reported as hazard ratios. A hazard ratio above one indicates higher event risk for one group or for a one-unit increase in a numeric predictor.
A value below one indicates lower risk. Hazard is not the same as probability, so a hazard ratio should not be described as a direct change in the chance of an event. The proportional hazards assumption says that the relative hazard between groups stays roughly stable through follow-up.
Researchers check this with plots, time interaction terms, and residual methods. If the assumption fails, they may split time into periods, add time-varying effects, or choose another model. Clear interpretation also needs the event definition, time origin, follow-up rules, and predictor units.