Learn R Programming

ingredients (version 2.3.0)

print.feature_importance_explainer: Print Generic for Feature Importance Object

Description

Print Generic for Feature Importance Object

Usage

# S3 method for feature_importance_explainer
print(x, ...)

Value

a data frame.

Arguments

x

an explanation created with feature_importance

...

other parameters.

References

Explanatory Model Analysis. Explore, Explain, and Examine Predictive Models. https://ema.drwhy.ai/

Examples

Run this code
library("DALEX")
library("ingredients")

model_titanic_glm <- glm(survived ~ gender + age + fare,
                         data = titanic_imputed, family = "binomial")

explain_titanic_glm <- explain(model_titanic_glm,
                               data = titanic_imputed[,-8],
                               y = titanic_imputed[,8],
                               verbose = FALSE)

fi_glm <- feature_importance(explain_titanic_glm)

fi_glm


Run the code above in your browser using DataLab