Skip to main content

Survival analysis built on top of scikit-learn

Project description

License readthedocs.org Digital Object Identifier (DOI)

Linux Build Status macOS Build Status Windows Build Status on AppVeyor codecov Codacy Badge

scikit-survival

scikit-survival is a Python module for survival analysis built on top of scikit-learn. It allows doing survival analysis while utilizing the power of scikit-learn, e.g., for pre-processing or doing cross-validation.

About Survival Analysis

The objective in survival analysis (also referred to as time-to-event or reliability analysis) is to establish a connection between covariates and the time of an event. What makes survival analysis differ from traditional machine learning is the fact that parts of the training data can only be partially observed – they are censored.

For instance, in a clinical study, patients are often monitored for a particular time period, and events occurring in this particular period are recorded. If a patient experiences an event, the exact time of the event can be recorded – the patient’s record is uncensored. In contrast, right censored records refer to patients that remained event-free during the study period and it is unknown whether an event has or has not occurred after the study ended. Consequently, survival analysis demands for models that take this unique characteristic of such a dataset into account.

Requirements

  • Python 3.8 or later

  • ecos

  • joblib

  • numexpr

  • numpy 1.17.3 or later

  • osqp

  • pandas 1.0.5 or later

  • scikit-learn 1.1

  • scipy 1.3.2 or later

  • C/C++ compiler

Installation

The easiest way to install scikit-survival is to use Anaconda by running:

conda install -c sebp scikit-survival

Alternatively, you can install scikit-survival from source following this guide.

Examples

The user guide provides in-depth information on the key concepts of scikit-survival, an overview of available survival models, and hands-on examples in the form of Jupyter notebooks.

Help and Support

Documentation

Bug reports

  • If you encountered a problem, please submit a bug report.

Questions

  • If you have a question on how to use scikit-survival, please use GitHub Discussions.

  • For general theoretical or methodological questions on survival analysis, please use Cross Validated.

Contributing

New contributors are always welcome. Please have a look at the contributing guidelines on how to get started and to make sure your code complies with our guidelines.

References

Please cite the following paper if you are using scikit-survival.

S. Pölsterl, “scikit-survival: A Library for Time-to-Event Analysis Built on Top of scikit-learn,” Journal of Machine Learning Research, vol. 21, no. 212, pp. 1–6, 2020.

@article{sksurv,
  author  = {Sebastian P{\"o}lsterl},
  title   = {scikit-survival: A Library for Time-to-Event Analysis Built on Top of scikit-learn},
  journal = {Journal of Machine Learning Research},
  year    = {2020},
  volume  = {21},
  number  = {212},
  pages   = {1-6},
  url     = {http://jmlr.org/papers/v21/20-729.html}
}

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

scikit-survival-0.19.0.tar.gz (2.5 MB view details)

Uploaded Source

Built Distributions

scikit_survival-0.19.0-cp310-cp310-win_amd64.whl (709.0 kB view details)

Uploaded CPython 3.10 Windows x86-64

scikit_survival-0.19.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.2 MB view details)

Uploaded CPython 3.10 manylinux: glibc 2.17+ x86-64

scikit_survival-0.19.0-cp310-cp310-macosx_10_13_x86_64.whl (759.1 kB view details)

Uploaded CPython 3.10 macOS 10.13+ x86-64

scikit_survival-0.19.0-cp39-cp39-win_amd64.whl (714.1 kB view details)

Uploaded CPython 3.9 Windows x86-64

scikit_survival-0.19.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.2 MB view details)

Uploaded CPython 3.9 manylinux: glibc 2.17+ x86-64

scikit_survival-0.19.0-cp39-cp39-macosx_10_13_x86_64.whl (760.0 kB view details)

Uploaded CPython 3.9 macOS 10.13+ x86-64

scikit_survival-0.19.0-cp38-cp38-win_amd64.whl (715.0 kB view details)

Uploaded CPython 3.8 Windows x86-64

scikit_survival-0.19.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.2 MB view details)

Uploaded CPython 3.8 manylinux: glibc 2.17+ x86-64

scikit_survival-0.19.0-cp38-cp38-macosx_10_13_x86_64.whl (752.4 kB view details)

Uploaded CPython 3.8 macOS 10.13+ x86-64

File details

Details for the file scikit-survival-0.19.0.tar.gz.

File metadata

  • Download URL: scikit-survival-0.19.0.tar.gz
  • Upload date:
  • Size: 2.5 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.10.7

File hashes

Hashes for scikit-survival-0.19.0.tar.gz
Algorithm Hash digest
SHA256 5f13814864792c46d748384a46e928622536088561eac45f9f73c6edefea0805
MD5 87defadf7a81602bcf830d3e86c90dcc
BLAKE2b-256 a35a438529c918f8111faf6986e82391be18d0271a275c465ccd35e09c41bcca

See more details on using hashes here.

File details

Details for the file scikit_survival-0.19.0-cp310-cp310-win_amd64.whl.

File metadata

File hashes

Hashes for scikit_survival-0.19.0-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 28aa866da177eb86ea69992c451c720fd6204f2285c6d3ace1c232de2e3ef0ef
MD5 5f3f495e1ee6dd3fc2e7e32d6677d8ee
BLAKE2b-256 8854256d706eb0c73cc75709418e1b2c2471f78871d4bd54e053396bc4b989d4

See more details on using hashes here.

File details

Details for the file scikit_survival-0.19.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for scikit_survival-0.19.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 505122fb5b3a6d7c83188a5548169de04c26bb901b1a6c460ac8e72ff1e2596d
MD5 f163e9046ed12c89afd667479b1bf292
BLAKE2b-256 0e8ab3629a41444b129d46e8142f029e621a1114375147e0a07d6fa57092d1de

See more details on using hashes here.

File details

Details for the file scikit_survival-0.19.0-cp310-cp310-macosx_10_13_x86_64.whl.

File metadata

File hashes

Hashes for scikit_survival-0.19.0-cp310-cp310-macosx_10_13_x86_64.whl
Algorithm Hash digest
SHA256 f6306c593d7b4df690635313c994d2915df5f2b290e30466386258d640a6535b
MD5 35ce36c0c04dcaefd30882359ff97ee7
BLAKE2b-256 b1dbab51338a8a27522fc73d67b62ff1f8e1192269f3b027fac60e37767d18c8

See more details on using hashes here.

File details

Details for the file scikit_survival-0.19.0-cp39-cp39-win_amd64.whl.

File metadata

File hashes

Hashes for scikit_survival-0.19.0-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 d1127f2f84564a379c6fcdb55e6e148645dff6643e28c55cc42ab4b3c6538b8a
MD5 e7fba348a957cf9ff49ed8c352b9e6ac
BLAKE2b-256 1c51f1c910b09b63b43c13dfeef6801e5c0d7287d5ed9cfa11fd3497b0153d47

See more details on using hashes here.

File details

Details for the file scikit_survival-0.19.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for scikit_survival-0.19.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 79d16fb73cbb79f4f8aa21d5390e247e2458019e6ee17fb4b11a86ba9f233ba1
MD5 2f98734a00e528b7d79e77c0e91d9ecb
BLAKE2b-256 788ac64ca5a006db83322dd6b777eda7e2d8d38b36423af8599900179c7b6269

See more details on using hashes here.

File details

Details for the file scikit_survival-0.19.0-cp39-cp39-macosx_10_13_x86_64.whl.

File metadata

File hashes

Hashes for scikit_survival-0.19.0-cp39-cp39-macosx_10_13_x86_64.whl
Algorithm Hash digest
SHA256 e8def0c6004c35b635852b82c590d406c5a35e470987287e9aaa87ea4c8fce58
MD5 704cf90496bc98cfb6a13e6db530639b
BLAKE2b-256 58cc683f42f35cbab5a391e6721a833985a5b02edc4ff55f31a84d67de51512a

See more details on using hashes here.

File details

Details for the file scikit_survival-0.19.0-cp38-cp38-win_amd64.whl.

File metadata

File hashes

Hashes for scikit_survival-0.19.0-cp38-cp38-win_amd64.whl
Algorithm Hash digest
SHA256 31d4a643579f0f862ce724de09b99e0eca13ed2c8bf4cc4f1e8d0fbd6b582fb7
MD5 eb6000a47dedfc7e722fa875a6b8b7d4
BLAKE2b-256 e3e1f7c4bcefc2fefe40ffd51cc49ef7301149a6ed3c90beec572c0ec2597641

See more details on using hashes here.

File details

Details for the file scikit_survival-0.19.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for scikit_survival-0.19.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 7d79703664017a7b5a28a4bb7f24b165a6b15aee0db96d0c0bb8b3c985a48b8b
MD5 9269d3e89abc254477056200bc9f0c4a
BLAKE2b-256 063d4d6c0e0620f3b03a8b56a875747e562812322cf8b1b3343ba102d98924d4

See more details on using hashes here.

File details

Details for the file scikit_survival-0.19.0-cp38-cp38-macosx_10_13_x86_64.whl.

File metadata

File hashes

Hashes for scikit_survival-0.19.0-cp38-cp38-macosx_10_13_x86_64.whl
Algorithm Hash digest
SHA256 f1a6cbfda7896877e5e20d5c63c8f07bc7a5d55dd335e20db142adea30ff376f
MD5 a60e4cbb36f45b7f4a3c25338bbbfcec
BLAKE2b-256 f3df0ac0464a4a0dac4107dfed8516ade1b90a1085839fd206bb59937a78834a

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page