Time-to-event prediction and survival prediction#

The skpro.survival module contains algorithms and composition tools for time-to-event prediction or survival prediction, i.e., tabular regression estimation with a probabilistic prediction mode, and optional right censoring.

All survival predictors in skpro can be listed using the skpro.registry.all_objects utility, using object_types="regressor_proba", filtering by capability:survival being True, optionally filtered by further tags. Valid tags can be listed using skpro.registry.all_tags.

Additionally, all probabilistic regressors can be used for survival prediction, by default they will ignore the censoring information. Note: this is different from subsetting to uncensored observations.

Composition#

The regression pipeline class Pipeline can be used to pipeline time-to-event prediction estimators.

Pipeline(steps)

Pipeline for probabilistic supervised regression.

Reduction to plain probabilistic regression#

The below estimators can be used to reduce a survival predictor to a plain probabilistic regressor, i.e., in the skpro.regression module.

These add the capability to take censoring into account.

FitUncensored(estimator)

Reduction to tabular probabilistic regression - fit on uncensored subsample.

ConditionUncensored(estimator)

Reduction to tabular probabilistic regression - conditioning on uncensored.

Reduction - adding predict_proba#

Simple strategies to use sklearn regressors for survival prediction are obtained from using any of the wrappers in skpro.regression, then applying reduction to tabular supervised probabilistic regression (above).

Model selection and tuning#

GridSearchCV(estimator, cv, param_grid[, ...])

Perform grid-search cross-validation to find optimal model parameters.

RandomizedSearchCV(estimator, cv, ...[, ...])

Perform randomized-search cross-validation to find optimal model parameters.

evaluate(estimator, cv, X, y[, scoring, ...])

Evaluate estimator using re-sample folds.

Proportional hazards models#

CoxPH([method, ties, missing, strata, alpha])

Cox proportional hazards model, partial likelihood or elastic net, statsmodels.

CoxPHlifelines([baseline_estimation_method, ...])

Cox proportional hazards models, from lifelines.

CoxPHSkSurv([alpha, ties, n_iter, tol, verbose])

Cox proportional hazards, from scikit-survival.

CoxNet([n_alphas, alphas, alpha_min_ratio, ...])

Cox proportional hazards model with elastic net penalty.

Accelerated failure time models#

AFTFisk([alpha_cols, beta_cols, ...])

Log-Logitsic/Fisk AFT model, from lifelines.

AFTLogNormal([mu_cols, sd_cols, ...])

Log-Normal AFT model, from lifelines.

AFTWeibull([scale_cols, shape_cols, ...])

Weibull AFT model, from lifelines.

Generalized additive survival models#

Tree models#

SurvivalTree([splitter, max_depth, ...])

Survival tree, from scikit-survival.

Tree ensemble models#

SurvivalForestSkSurv([n_estimators, ...])

Random survival forest from scikit-survival.

SurvivalForestXtraSkSurv([n_estimators, ...])

Survival random forest with extra randomization-averaging, from scikit-survival.

SurvGradBoostSkSurv([loss, learning_rate, ...])

Gradient-boosted survival trees with proportional hazards loss, from sksurv.

SurvGradBoostCompSkSurv([loss, ...])

Survival Gradient boosting component-wise least squares, from sksurv.

Base#

Survival predictors inherit from the same base class as tabular probabilistic regressors.

BaseProbaRegressor()

Base class for probabilistic supervised regressors.