cnellington / Contextualized

An SKLearn-style toolbox for estimating and analyzing models, distributions, and functions with context-specific parameters.
http://contextualized.ml/
GNU General Public License v3.0
65 stars 9 forks source link

Add ContextualGAM #121

Closed blengerich closed 2 years ago

blengerich commented 2 years ago

This PR adds the ContextualGAM used in Automated interpretable discovery of heterogeneous treatment effectiveness: A COVID-19 case study as an easy handler.

With the improved flexibility of the Contextualized package, the new model is a very simple extension of the already-provided easy handlers. In particular, there are 2 new handlers:

The frozen EBMs used in the JBI paper can be included with the keyword argument base_y_predictor.

For demos, we have included a simple introductory demo and the benchmarking MIMIC-IV experiments detailed in the JBI paper.

Plotting the results is still not perfect and relies on some helper functions defined in scContextualized. This should likely be improved in the future, but is not critical.

review-notebook-app[bot] commented 2 years ago

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

cnellington commented 2 years ago

Looks great! Would it be easy to add an example including the frozen EBM? Merging but leaving this branch open for the EBM addition. Feel free to close if it won't be easy to add.