scikit-survival-analysis

Installation
SKILL.md

scikit-survival -- Survival Analysis

Overview

scikit-survival is a Python library for time-to-event analysis built on scikit-learn. It handles right-censored data (observations where the event has not yet occurred) using Cox models, ensemble methods, survival SVMs, and non-parametric estimators. All models follow the scikit-learn fit/predict API and integrate with Pipelines, cross-validation, and GridSearchCV.

When to Use

  • Modeling time-to-event outcomes with right-censored data (clinical trials, reliability)
  • Fitting Cox proportional hazards models (standard or elastic net penalized)
  • Building ensemble survival models (Random Survival Forest, Gradient Boosting)
  • Training survival SVMs for margin-based learning on medium-sized datasets
  • Evaluating survival predictions with censoring-aware metrics (C-index, Brier score, AUC)
  • Estimating non-parametric survival curves (Kaplan-Meier, Nelson-Aalen)
  • Analyzing competing risks with cumulative incidence functions
  • High-dimensional survival data with automatic feature selection (CoxNet L1/L2)
  • For simpler parametric models (Weibull, log-normal AFT) or statistical tests (log-rank), use lifelines
  • For deep learning survival models, use pycox or torchlife
Related skills

More from jaechang-hits/sciagent-skills

Installs
9
GitHub Stars
152
First Seen
Mar 16, 2026