scikit-survival

Model time-to-event data with scikit-survival Cox and ensemble methods.

15|2|Updated Dec 17, 2025
One-click install
npx skills add https://github.com/rubensliv/k-dense-ai --skill scikit-survival-rubensliv
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: scikit-survival
Source: https://github.com/rubensliv/k-dense-ai/tree/main/scientific-skills/scikit-survival
Command: npx skills add https://github.com/rubensliv/k-dense-ai --skill scikit-survival-rubensliv

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Survival analysis and time-to-event modeling in Python, with support for censored data, Cox models, ensemble methods, survival SVMs, and competing risks.

Core Features & Use Cases

  • CoxPHSurvivalAnalysis, CoxnetSurvivalAnalysis, IPCRidge for regression-style survival modeling
  • RandomSurvivalForest, GradientBoostingSurvivalAnalysis, ComponentwiseGradientBoostingSurvivalAnalysis, ExtraSurvivalTrees for non-parametric and ensemble methods
  • Survival SVMs (FastSurvivalSVM, FastKernelSurvivalSVM, HingeLossSurvivalSVM) for margin-based ranking
  • Data handling: Surv objects, one-hot encoding, preprocessing, and scikit-learn pipeline integration
  • Evaluation: concordance index, time-dependent AUC, Brier score, competing risks, and non-parametric estimators
  • References: guides and docs in references/*.md

Quick Start

Install scikit-survival, load a dataset, fit a model like CoxPHSurvivalAnalysis, and evaluate with C-index or IPCW.

Frequently Asked Questions about scikit-survival

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I perform survival analysis with censored data in Python?▼

Survival analysis with censored data in Python uses scikit-survival to handle time-to-event modeling, providing models like CoxPHSurvivalAnalysis to process censored observations and generate actionable risk insights.

Can I use scikit-learn pipelines with survival models like Random Survival Forest?▼

Yes, survival models like Random Survival Forest integrate directly with scikit-learn pipelines, allowing you to chain preprocessing steps such as one-hot encoding with model fitting and evaluation for censored data.

What evaluation metrics are available for time-to-event modeling?▼

Time-to-event modeling evaluation metrics include the concordance index, time-dependent AUC, and Brier score, which assess survival model ranking performance and prediction accuracy for censored data.

What's the best way to model competing risks in survival analysis?▼

Modeling competing risks in survival analysis involves using scikit-survival's specialized estimators and evaluation functions to correctly handle multiple event types and generate accurate time-to-event predictions.

How do Survival SVMs differ from Cox models for time-to-event modeling?▼

Survival SVMs use margin-based ranking for time-to-event modeling, whereas Cox models like CoxPHSurvivalAnalysis and its penalized variants use regression-style estimation to evaluate covariate effects on survival times.