TreeSHAP

Calculate SHAP values for your model

treeshap()

Calculate SHAP values of a tree ensemble model.

treeshap.object

treeshap results

treeshap_multioutput.object

treeshap results for multi-output model

Unifiers

Convert your model into a standardized representation

unify()

Unify tree-based model

gbm.unify()

Unify GBM model

lightgbm.unify()

Unify LightGBM model

randomForest.unify()

Unify randomForest model

ranger.unify()

Unify ranger model

ranger_surv.unify()

Unify ranger survival model

xgboost.unify()

Unify XGBoost model

model_unified.object

Unified model representation

model_unified_multioutput.object

Unified model representations for multi-output model

Plotting functions

Plot explanation results

plot_contribution()

SHAP value based Break-Down plot

plot_feature_dependence()

SHAP value based Feature Dependence plot

plot_feature_importance()

SHAP value based Feature Importance plot

plot_interaction()

SHAP Interaction value plot

colors_discrete_drwhy() colors_breakdown_drwhy()

DrWhy color palettes for ggplot objects

theme_drwhy() theme_drwhy_vertical()

DrWhy Theme for ggplot objects

Printing functions

print(<model_unified>)

Prints model_unified objects

print(<model_unified_multioutput>)

Prints model_unified_multioutput objects

print(<treeshap>)

Prints treeshap objects

print(<treeshap_multioutput>)

Prints treeshap_multioutput objects

Utility functions

set_reference_dataset()

Set reference dataset

predict(<model_unified>)

Predict

is.model_unified()

Check whether object is a valid model_unified object

is.treeshap()

Check whether object is a valid treeshap object

Data

fifa20

Attributes of all players in FIFA 20