2
$\begingroup$

Using Python, I created a neural network to perform predictions on a binary class dataset (e.g. will a passenger survive the Titanic?). I am using the SHAP package to explain individual predictions. For all of the instances in this dataset, the visualization outputted by SHAP has an output value of 0 and the higher/lower graph is empty (there are no features listed).

shap.force_plot(k_explainer.expected_value[0], k_shap_values[0], label_test_X.iloc[0])

When I use a different dataset and run the line above, SHAP outputs a graph and lists features.

What does an empty SHAP graph mean, especially in this case where there is an empty graph for each instance of a dataset? I am reading the documentation to help understand this situation, but I appreciate any insight into this.

Thank you in advance for the help!

$\endgroup$
1
  • 1
    $\begingroup$ Are you sure this is not due to a problem with your variables ? (Basically a NAN somewhere, or a bad formatting) $\endgroup$
    – lcrmorin
    Jan 24 '20 at 15:50
0
$\begingroup$

that means shap values were nan.Model was not able to compute shap values.

$\endgroup$

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.