Turnbull#

class relife.lifetime_model.Turnbull(tol=0.0001, lowmem=False)[source]#

Turnbull estimator.

Methods

fit

Compute the non-parametric estimations with respect to lifetime data.

sf

The survival function estimation

fit(time, event=None, entry=None, departure=None, inplace=False)[source]#

Compute the non-parametric estimations with respect to lifetime data.

Parameters:
timendarray (1d or 2d)

Observed lifetime values.

eventndarray of boolean values (1d), default is None

Boolean indicators tagging lifetime values as right censored or complete.

entryndarray of float (1d), default is None

Left truncations applied to lifetime values.

departurendarray of float (1d), default is None

Right truncations applied to lifetime values.

inplaceboolean, default is True

If true, estimations are stored in the object

sf()[source]#

The survival function estimation

Returns:
tuple of 2 ndarrays

A tuple containing the timeline and the estimated values