scikit-survival

Model time-to-event data with censoring using scikit-survival in Python.

3|Updated Jan 1, 2026
One-click install
npx skills add https://github.com/kjgarza/marketplace-claude --skill scikit-survival-kjgarza
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: scikit-survival
Source: https://github.com/kjgarza/marketplace-claude/tree/main/plugins/scholarly-comms-researcher/skills/scikit-survival
Command: npx skills add https://github.com/kjgarza/marketplace-claude --skill scikit-survival-kjgarza

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill provides a comprehensive toolkit for survival analysis in Python, enabling time-to-event modeling with censored data using the scikit-survival library and its integration with scikit-learn.

Core Features & Use Cases

  • Cox proportional hazards models (CoxPHSurvivalAnalysis) and penalized variants (CoxnetSurvivalAnalysis, IPCRidge)
  • Ensemble methods (RandomSurvivalForest, GradientBoostingSurvivalAnalysis, ExtraSurvivalTrees) and survival SVMs (FastSurvivalSVM, FastKernelSurvivalSVM)
  • Competing risks analysis, cause-specific hazards, and non-parametric estimators
  • Data loading, preprocessing, evaluation metrics (concordance index, time-dependent AUC, Brier score)
  • Practical workflows for research, benchmarking, and applied analytics

Quick Start

Load a dataset with sksurv.datasets.load_gbsg2, fit CoxPHSurvivalAnalysis, and generate risk scores.

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 time-to-event data in Python?

Survival analysis with censored time-to-event data in Python can be performed using the scikit-survival toolkit, which models censored records via Cox proportional hazards, ensemble methods, and survival SVMs.

Can I use scikit-learn estimators for survival analysis and competing risks?

Scikit-learn estimators can be used for survival analysis and competing risks through the scikit-survival library, which provides compatible wrappers for survival SVMs, RandomSurvivalForest, and cause-specific hazard modeling.

What is the best way to evaluate a Cox proportional hazards model in Python?

The best way to evaluate a Cox proportional hazards model in Python is using survival-specific metrics like the concordance index, time-dependent AUC, and Brier score, all integrated into the scikit-survival evaluation workflows.

Does scikit-survival support Random Survival Forests and penalized Cox models?

Scikit-survival supports Random Survival Forests and penalized Cox models, offering CoxnetSurvivalAnalysis for elastic-net penalization alongside ensemble methods like ExtraSurvivalTrees and GradientBoostingSurvivalAnalysis.

How do I handle data preprocessing and loading for time-to-event modeling?

Data preprocessing and loading for time-to-event modeling is handled through scikit-survival utilities, allowing you to load built-in datasets like GBSG2 and transform user-provided survival data into the required censored format.

When should I use survival SVMs instead of Cox models for time-to-event data?

Survival SVMs should be used instead of Cox models for time-to-event data when you need non-linear decision boundaries, utilizing FastSurvivalSVM or FastKernelSurvivalSVM rather than relying on proportional hazard assumptions.