model_halfnormal {auditor}R Documentation

Create Halfnormal Explanation

Description

Creates auditor_model_halfnormal object that can be used for plotting halfnormal plot.

Usage

model_halfnormal(object, quant = FALSE, ...)

modelFit(object, quant = FALSE, ...)

Arguments

object

An object of class explainer created with function explain from the DALEX package.

quant

if TRUE values on axis are on quantile scale.

...

other parameters passed do hnp function.

Value

An object of the class auditor_model_halfnormal.

References

Moral, R., Hinde, J., & Dem├ętrio, C. (2017). Half-Normal Plots and Overdispersed Models in R: The hnp Package.doi:http://dx.doi.org/10.18637/jss.v081.i10

Examples

data(titanic_imputed, package = "DALEX")

# fit a model
model_glm <- glm(survived ~ ., family = binomial, data = titanic_imputed)

glm_audit <- audit(model_glm,
                   data = titanic_imputed,
                   y = titanic_imputed$survived)

# validate a model with auditor
mh <- model_halfnormal(glm_audit)
mh

plot(mh)


[Package auditor version 1.3.3 Index]