references on how to use shap values without the shap package

I am familiar with the shap python package and how to use it, I also have a pretty good idea about shap values in general, but it is still new to me. What I'm requesting are references (ideally python custom code in blog posts) to explain how to take an array of raw shap values (of shape num_features X num_samples) and get...

  1. feature importance
  2. interaction terms
  3. any other calculations the shap package does

My motivation for this is that I want to understand how them metrics are calculated in order to be sure I am using then and interpreting them correctly.


edit

it appear that shap contribution can be calculated by np.nanmean(np.abs(shap_values), axis = 0) but I still would like references that talk about this even though it does make sense.

Topic gradient-boosting-decision-trees shap data-science-model python

Category Data Science

About

Geeks Mental is a community that publishes articles and tutorials about Web, Android, Data Science, new techniques and Linux security.