create_shimex: Create SHIny app for Model EXploration

Description Usage Arguments Examples

View source: R/create_shimex.R

Description

creates files for Shiny App and runs Shiny.

Usage

1
2
3
4
create_shimex(explainer, new_obs, data = explainer$data,
  selected_variables = NULL, selected_explainers = c("CeterisParibus",
  "BreakDown", "Shap", "LocalModel", "Lime"), main_dir = NULL,
  delete = TRUE, ...)

Arguments

explainer

explainer created with function 'DALEX::explain()'

new_obs

a new observation with columns that corresponds to variables used in the model

data

selected_variables

a vector of variable names that will be shown in input panel,

selected_explainers

a vector of explainers, that will be shown in the app. Possible choices: c('CeterisParibus', 'BreakDown', 'Shap', 'Shap_iml', 'Shap_shapper', 'LocalModel', 'Lime', 'Lime_iml') The default value are explainers implemented by MI2 DataLab.

main_dir

string, path where shiny files should be stored.

delete

logical value, if TRUE shiny files are deleted on exit of function.

...

other parameters.

Examples

1
2
3
4
5
6
7
## Not run: 
library(randomForest)
model_rm <- randomForest(life_length ~., data = DALEX::dragons, ntree = 200)
explainer <- DALEX::explain(model_rm)
create_shimex(explainer,  DALEX::dragons[1, ])

## End(Not run)

monikachudek/shimex documentation built on Nov. 18, 2019, 8:37 a.m.