scikit-survival

Perform survival analysis on censored data with Cox models and ensemble methods.

52|6|Updated Nov 24, 2025
One-click install
npx skills add https://github.com/ovachiever/droid-tings --skill scikit-survival
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: scikit-survival
Source: https://github.com/ovachiever/droid-tings/tree/main/skills/scikit-survival
Command: npx skills add https://github.com/ovachiever/droid-tings --skill scikit-survival

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Comprehensive survival analysis tooling in Python, including Cox models, ensemble methods, survival SVMs, and evaluation metrics.

Core Features & Use Cases

  • ✅ CoxPH, Coxnet, and AFT models
  • ✅ RandomSurvivalForest, GradientBoostingSurvivalAnalysis
  • ✅ Survival SVMs and distance-based methods
  • ✅ Evaluation metrics: C-index, time-dependent AUC, Brier score

Quick Start

Load survival data, fit a model (e.g., CoxPHSurvivalAnalysis), and evaluate predictive performance.

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 on censored time-to-event data?

Survival analysis models time-to-event outcomes when some observations are censored. Use scikit-survival to load data as Surv objects, fit models like Cox proportional hazards or ensemble methods (Random Survival Forest, Gradient Boosting), and evaluate with concordance index or time-dependent AUC to predict risk scores and survival functions.

What's the difference between Cox models, Random Survival Forest, and Survival SVMs?

Cox proportional hazards model hazard ratios parametrically; Random Survival Forest and Gradient Boosting capture non-linear interactions through ensemble splits; Survival SVMs optimize margin-based ranking. Choose Cox for interpretability, ensembles for predictive performance on complex data, and SVMs for distance-based risk stratification.

How do I evaluate survival model performance with the right metrics?

Concordance index (C-index) measures ranking accuracy of risk predictions. Time-dependent AUC captures discrimination at specific time points. Brier score quantifies prediction error for survival probabilities. Use all three to assess calibration, discrimination, and overall predictive accuracy across your time-to-event model.

Can I handle competing risks and multiple event types in survival analysis?

Yes, scikit-survival supports competing risks workflows where multiple event types can occur. Model each risk separately or jointly using appropriate Surv object specifications, enabling prediction of event-specific cumulative incidence and risk stratification in complex clinical or observational settings.

What preprocessing steps should I apply before fitting a survival model?

Preprocess with imputation for missing values, encoding for categorical features, and scaling for numeric predictors. Handle time and event columns correctly in Surv objects, then fit and validate models. Proper preprocessing ensures model convergence and reliable risk score generation.