Skip to content

sdrelton/PREDICT

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PREDICT

PREDICT - Pragmatic Recalibration and Evaluation of Drift In Clinical Tools

License Tests DOI

The PREDICT library provides a way to assess, and test potential repairs, for binary prediction models that might drift over time. Although originally designed for use in healthtech application, the methods are applicable to any binary prediction model which might experience temporal drift.

Getting Started

Installation

To clone the repo:

git clone https://github.com/sdrelton/PREDICT.git

To create a suitable environment we suggest:

  • Build conda environment and install requirements via conda env create -f environment.yml
  • Activate environment conda activate predict_env

Examples

We have a number of examples to demonstrate common use-cases.

Detect and Repair Methodology Comparison

We compare methods to detect and repair temporal drift for four scenarios:

  1. Fast predictor change - COVID pandemic
  2. Slow predictor change - population-based BMI increase
  3. Outcome drift - change in prevalence of myocardial infarctions
  4. Multivariate drift - the importance of BMI increases whilst age is deemed less important by models

Methods used to detect and repair temporal drift

Notebook for detection method comparison

Notebook for comparing model performance from each PREDICT method

Documentation

Full documentation generated by Sphinx can be found here.

Team

The core PREDICT team is:

The PREDICT project is funded by the National Institute for Health and Social Care Research (Grant NIHR206843).

Test the code is working

To run the tests, use the following command in PowerShell:

python -m pytest -v tests/

The heart disease data used for testing this code can be found here.

Janosi, A., Steinbrunn, W., Pfisterer, M., & Detrano, R. (1989). Heart Disease [Dataset]. UCI Machine Learning Repository. https://doi.org/10.24432/C52P4X.

About

PREDICT - Pragmatic Recalibration and Evaluation of Drift In Clinical Tools

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 2

  •  
  •