shap values scale differ for model type
Hi! I've got an observation and curious if the developers had any thoughts.
For tree-based binary classifcation problems, I've noticed that when computing Shapley values for XGB, the values represent the log-odds space, i.e., \sigmoid(\sum_i \phi_i) = f(x), but when computing Shapley for RF, the values represent the probability space, i.e., \sum_i \phi_i = f(x). Other than attempting a non-linear (and I believe non-unique) transformations from one space to another, how else can we create consistent explanations, e.g., XGB and RF both return Shapley values in the probability space?
Thank you.
Quick followup - searched through the backlog of closed issues, specifically #29. The implementation and discussion of how to scale the values from log-odds into probability space are outlined therein. Thank you for that.
Is there current functionality that can transform the probability space into the log-odds space (for RF models)?
Thank you.
There is not currently a function to approximate the mapping of SHAP values through a logistic (or logit) function. It is on a list to work on something better than just a linear rescaling.
The reason the RF is in probability space and XGB is in log-odds is because the RF keeps probabilities in its leaves and XGB keeps log-odds.
Great. Thanks for the prompt reply.