Kaplan–Meier Survival & Log-rank
Censoring-aware survival · median · risk table · log-rank
Kaplan–Meier Survival & Log-rank
Censoring-aware survival · median · risk table · log-rank
Calculated locally in this browserColumn order: subject_id, group, time, event_1_censored_0
| subject_id | group | time | event_1_censored_0 | |
|---|---|---|---|---|
Paste CSV / TSV
Analysis result
| Group | N | Events | Censored | Median survival | Final survival |
|---|---|---|---|---|---|
| Control | 4 | 3 | 1 | 10 | 0.25 |
| Treatment | 4 | 2 | 2 | 20 | 0 |
⚠ Kaplan–Meier and log-rank assume non-informative censoring; inspect censoring patterns and prespecified endpoints.
Use the result with confidence.
Use this Kaplan–Meier calculator to estimate time-to-event survival by group while retaining each subject’s event or censoring status. It reports events, censoring, median survival when reached, final estimated survival and a log-rank comparison, and produces a copy-ready curve with censor marks and confidence bands.
Open the calculatorCheck the calculation in context.
Median survival reached in one group
When is median survival reportable?
- Order observed event times within the group.
- Update survival at each event using the number at risk immediately before that time.
- Find the first time where the estimated survival is 0.50 or lower.
That event time is the Kaplan–Meier median estimate for the group.
Interpretation: If the curve never crosses 0.50, report the median as not reached rather than substituting the longest follow-up.
A subject censored at day 16
How does censoring affect the risk set?
- The subject contributes follow-up through day 16.
- The subject is removed from later risk sets without being counted as an event.
- The curve does not drop at the censoring time.
Censoring changes later denominators but does not itself reduce survival probability.
Interpretation: This interpretation relies on a defensible non-informative censoring assumption and a clearly defined time origin and event.
Correct numbers can still lead to a poor experiment.
Coding censoring backwards
Reversing event and censor indicators changes every risk-set calculation.
Confirm the page schema—event 1, censored 0—and test it with a small known dataset before importing a study.
Reporting the curve tail without risk counts
A stable-looking tail may be supported by only one or two subjects.
Report group N, events, censoring and numbers at risk at meaningful time points.
Treating log-rank p as an effect size
The test assesses evidence against equal survival functions but does not quantify treatment magnitude.
Report survival estimates and an appropriate effect estimate with uncertainty from a prespecified model when required.
Document the calculation clearly.
Copy a methods-ready sentence or preparation checklist, then adapt it to your actual protocol, instrument and acceptance criteria.
Time-to-event outcomes were summarized by Kaplan–Meier estimation using the stated time origin, event definition and censoring rule; groups were compared with the prespecified log-rank test.
Report group sizes, events, censoring, median survival with uncertainty when available, meaningful time-point estimates, risk counts and the log-rank result without interpreting p-value as effect size.
Questions researchers often ask.
What does a censor mark mean on a Kaplan-Meier curve?
It shows the last known event-free follow-up for a subject whose exact event time was not observed. The subject contributes to the risk set until that time.
Why is median survival sometimes not reached?
The estimated curve did not fall to 0.50 during observed follow-up. The longest observation should not be substituted for the median.
What does the log-rank test compare?
It compares observed and expected events across groups over event times under the null hypothesis of equal survival functions.
Can this calculator replace a prespecified statistical analysis?
No. Covariate adjustment, competing risks, interval censoring, clustered data, proportional-hazards modeling and regulated reporting require an appropriate validated workflow and statistical review.
Data requirements
Enter subject ID, group, non-negative time and event status (1=event, 0=censored).
subject_id, group, time, event_1_censored_0Review before reporting
Research use only. Validate raw data, exclusions and interpretation against the approved analysis plan.
Check raw observations, excluded rows, model assumptions and study-specific acceptance criteria before using the result.
Transparent analysis
Inputs are processed locally in your browser. Review the calculation policy, limitations and verification approach before reporting a result.
Read the methodology →A result you can audit.
Implementation check
The analysis keeps event status explicit, orders event times and displays group curves with at-risk context rather than reducing the data to a single median.
Interpretation boundary
Kaplan-Meier estimates rely on defensible time origins and censoring assumptions. Small risk sets and late-tail estimates should be interpreted cautiously; clinical decisions require validated statistical workflows.
Method references
Methods to Analyse Time-to-Event Data: The Kaplan-Meier Survival CurveIndian Journal of Anaesthesia / PMCKaplan-Meier estimation, censoring and comparison context.
Survival analysis: Part I — analysis of time-to-eventBritish Journal of Cancer / PMCInterpretation of survival functions, censoring and common limitations.
Two-subject survival steps
Kaplan–Meier product-limit estimate at each event time.
- Two subjects at risk initially
- One event at day 2
- One event at day 4
- No censoring
- S(0) = 1.00
- S(2) = 0.50
- S(4) = 0.00
Scope: A deterministic estimator check; inferential interpretation requires study context.
Review and correction history
12 August 2026 · Internal implementation review
Censoring and risk-set logic review complete. Formula behavior, unit handling, limitations and linked references were checked internally.
Independent reviewer: Not yet published. A name, relevant qualification, date and exact scope will appear here only after a real review is completed.
Source-informed and internally checked; independent scientific or regulatory validation is not claimed. Research use only.