statable Statistics for study and research

How long does it take until an event? (Kaplan-Meier)

In brief

You want to know how long it takes until something happens - for example a study dropout or reaching a learning goal - and whether groups differ in this. Not everyone has experienced the event when observation ends: they are censored. Kaplan-Meier uses them too and shows as a step curve what proportion has not yet experienced the event at each time.

What the table looks like

One row per person. You need the column with the time (a number: semesters, days, weeks - up to the event or to the end of observation) and a column that says whether the event occurred (two values, such as 0 and 1). Optional: a column with the groups (2 to 8). Statable suggests which value is the event; you can switch it.

If the event column has only one value, the checklist says how Statable reads it. If everyone experienced the event (for example only 1), this is a valid case without censoring: Statable calculates the curve, median and interval as R survfit does. If everyone is censored (for example only 0), nothing occurred for anyone - the curve would stay at 100% and there is nothing to estimate.

Reading the result

Requirements and limits

If several characteristics are to act on the time to the event at once (group, age, prior achievement), "More options" offers the Cox regression with hazard ratios. It calculates with R and is described in the article "Cox regression".

Log-rank: χ²(1) = 3.40, p = .065; Mdn (maintenance) = 31, 95% CI [18, -]; Mdn (no maintenance) = 23, 95% CI [8, -]; 23 people, 18 events; - = not reached

For specialists

Own code, checked against R (survival 3.8: survfit with conf.type = "log", summary with times, survdiff with rho = 0; data aml and lung). Product-limit estimator, Greenwood standard error, interval on the log scale (capped at 1). Median and limits as in print(survfit): the first time the curve lies below 50%; if it lies exactly at 50%, the midpoint to the next step. Log-rank after Mantel-Cox with the covariance from the hypergeometric distribution, df = groups − 1; pairwise one test each with df = 1, Holm. Weighted variants (Breslow, Tarone-Ware, Peto-Peto) and Cox regression are not offered by Statable.

Typical examples

Related

Open in Statable