- shap.plots.waterfall
shap.plots.waterfall(shap_values[0])
에러남
AttributeError: 'numpy.ndarray' object has no attribute 'base_values'
- in my case(SHAP version 0.39.0)
# waterfall plot
#method1
shap.plots._waterfall.waterfall_legacy(shap.TreeExplainer(model=model_new, data=X_test_features_ev, model_output='probability').expected_value, shap_values_t3[534])
# method2
explainer = shap.TreeExplainer(model=model_new, data=X_test_features_ev, model_output='probability')
shap.plots._waterfall.waterfall_legacy(explainer.expected_value, shap_values_t3[534])