I am trying to practice and learn shapley value approach to explain my predictions on a binary classification problem. However am having difficulty in understanding the below plot.

enter image description here

1) Does it indicate the day_2_balance influences prediction to 1? or does blue values leads to prediction 1

2) What about the axis scale? (-4.357 to 5.643)

3) What does base value mean?

4) When I hover around the pink color , I see few more column names with some values. What do they indicate?

5) does the size of features represent their importance? Meaning PEEP_min=5 has a larger size than other features?

6) What does higher to lower and lower to higher indicate?

Can someone help me with this?


I've never practiced this package myself, but I've read a few analyses based on SHAP, so here's what I can say:

  1. A day_2_balance of 532 contributes to increase the predicted output. In this area, such a value of day_2_balance would let to higher predictions.
  2. The axis scale represents the predicted output value scale. The actually predicted value is in bold font (-2.98). I don't know if the min and max values of the scale represent true min and max of the model predicted values. They more likely result from automatic scaling of the plot.
  3. Base value should be the mean value of the estimator over the whole input space.
  4. Those indicate the other features of which value influence the prediction to a higher value. Features are sorted by local importance, so those are features that have lower influence than those visible.
  5. Yes, but only locally. On some other locations, you could have other contributions
  6. higher/lower is a caption. It indicates if each feature value influences the prediction to a higher or lower output value.

From the example plot, you can draw the following interpretation: "sample n°4100 is predicted to be -2.92, which is much lower than the average predicted value (~0.643), mostly due to the specific values of features PEEP_min(5), Fi02_100_max (50), etc., and although day_2_balance is 532".

  • $\begingroup$ Hi, upvoted for the help.but when my output class is 0 or 1 why does it predict it as -2.92? I mean am working on binary classification problem $\endgroup$ – The Great Dec 27 '19 at 9:08
  • $\begingroup$ Sorry, did not get that at first sight. Explanations above are for regression. I'm not quite sure how it works for multi-output cases (including classification), this should be some kind of score for the selected class, higher score meaning that the prediction tends towards this class. So in that case, the tested class would not be favoured by the model, due to the explanations listed in my original answer. As this is a binary problem, if you try the other class, you should get reversed results, with more red. $\endgroup$ – Romain Reboulleau Dec 27 '19 at 21:55

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.