update_data: Update data of an explainer object

Description Usage Arguments Value Examples

View source: R/misc_update.R

Description

Function allows users to update data an y of any explainer in a unified way. It doesn't require knowledge about structre of an explainer.

Usage

1
update_data(explainer, data, y = NULL, verbose = TRUE)

Arguments

explainer

- explainer object that is supposed to be updated.

data

- new data, is going to be passed to an explainer

y

- new y, is going to be passed to an explainer

verbose

- logical, indicates if information about update should be printed

Value

updated explainer object

Examples

1
2
3
aps_lm_model4 <- lm(m2.price ~., data = apartments)
aps_lm_explainer4 <- explain(aps_lm_model4, data = apartments, label = "model_4v")
explainer <- update_data(aps_lm_explainer4, data = apartmentsTest, y = apartmentsTest$m2.price)

DALEX documentation built on July 8, 2020, 7:17 p.m.

Related to update_data in DALEX...