Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to apply shap model to DF model to interpret features? #109

Open
Leopoldxxx opened this issue Jun 6, 2022 · 2 comments
Open

How to apply shap model to DF model to interpret features? #109

Leopoldxxx opened this issue Jun 6, 2022 · 2 comments

Comments

@Leopoldxxx
Copy link

How to apply shap model to DF model to interpret features? I tried to apply it directly, but suggested that the model was not in the SHAP package.
https://github.com/slundberg/shap.
image
I suggest that the author improve the interpretability of the DF model,thanks.

@xuyxu
Copy link
Member

xuyxu commented Jun 6, 2022

Hi @Leopoldxxx, deep forest is currently not supported by SHAP, which requires much work from contributors in that community ;-(

@rebel55555
Copy link

Hi @Leopoldxxx , you can try using the following:

model = CascadeForestClassifier(random_state=1)
explainer = shap.Explainer(model.predict,X_val.values)
shap_values = explainer(X_val)
shap.plots.bar(shap_values)

It might work for you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants