Skip to content
simple customizable risk scores in python
Python Shell
Branch: master
Clone or download
Latest commit edda527 Jan 22, 2020

README.md

risk-slim

risk-slim is a machine learning method to learn customized risk scores from data.

Background

Risk scores are simple models that let users make quick risk predictions by adding and subtracting a few small numbers (see 500 + medical risk scores at mdcalc.com or the mdcalc iOS app).

Video

RiskSLIM KDD

Customized Risk Score for ICU seizure prediction

Here is a risk score for ICU risk prediction from our paper.

References

If you use risk-slim in your research, please cite one of the following papers:

  1. Learning Optimized Risk Scores
    Berk Ustun and Cynthia Rudin
    Journal of Machine Learning Research (JMLR), 2019.

  2. Optimized Risk Scores
    Berk Ustun and Cynthia Rudin
    23rd ACM SIGKDD International Conference on Knowledge Discovery and Data Mining (KDD), 2017.

@article{ustun2019jmlr,
  author  = {Ustun, Berk and Rudin, Cynthia},
  title   = {{Learning Optimized Risk Scores}},
  journal = {{Journal of Machine Learning Research}},
  year    = {2019},
  volume  = {20},
  number  = {150},
  pages   = {1-75},
  url     = {http://jmlr.org/papers/v20/18-615.html}
}

@inproceedings{ustun2017kdd,
  author  = {Ustun, Berk and Rudin, Cynthia},
  booktitle = {Proceedings of the 23rd ACM SIGKDD International Conference on Knowledge Discovery and Data Mining},
  organization = {ACM},
  title = {{Optimized Risk Scores}},
  year = {2017}
}

Package Details

Installation

Run the following snippet in a Unix terminal to install risk-slim and complete a test run.

git clone https://github.com/ustunb/risk-slim
cd risk-slim
pip install -e . 		# install in editable mode  
bash batch/job_template.sh 	# batch run

Requirements

  • Python 3.5+
  • CPLEX 12.6+

The code may work with older versions of Python and CPLEX, but this will not be supported.

CPLEX

CPLEX is cross-platform commercial optimization tool with a Python API. It is free for students and faculty members at accredited institutions. To get CPLEX:

  1. Register for IBM OnTheHub
  2. Download the IBM ILOG CPLEX Optimization Studio from the software catalog
  3. Install CPLEX Optimization Studio.
  4. Setup the CPLEX Python API as described here.

If you have problems installing CPLEX, check the CPLEX user manual or the CPLEX forums.

Development Roadmap

If you are interested in contributing, please reach out to berk@seas.harvard.edu!

  • simplify installation
  • convenience functions for batch computing
  • refactoring package for future development
  • sci-kit learn API
  • reporting tools (roc curves, calibration plots, model reports)
  • support for open-source solver
  • documentation
You can’t perform that action at this time.