check_residuals_trend: Checks for trend in residuals

View source: R/check_residuals.R

check_residuals_trendR Documentation

Checks for trend in residuals

Description

Calculates loess fit for residuals and then extracts statistics that shows how far is this fit from one without trend

Usage

check_residuals_trend(object, B = 20)

Arguments

object

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

B

number of samplings

Value

standardized loess fit for residuals

Examples

library(DALEX)
dragons <- DALEX::dragons[1:100, ]
lm_model <- lm(life_length ~ ., data = dragons)
lm_exp <- explain(lm_model, data = dragons, y = dragons$life_length)
library(auditor)
check_residuals_trend(lm_exp)

auditor documentation built on Nov. 2, 2023, 6:13 p.m.