cookDist: Visualize Cook's distances

Description Usage Arguments Details Value Author(s) Examples

View source: R/cookDist.R

Description

Graphical visualization of Cook's distances for each observation within input model.

Usage

1
cookDist(object, label.id, n.label.id, xlab, ylab, pos, ...)

Arguments

object

object of class 'influence', see Details.

label.id

labels of observations, should be a vector with n elements.

n.label.id

number of observations with highest Cook's distance to label in the plot.

xlab

title for the x axis.

ylab

title for the y axis.

pos

position of observations labels. Values 1, 2, 3, 4 respectively indicate below, left, above, right.

...

further arguments passed to plot.

Details

This function only works with objects given as output from influenceDiag, it takes Cook's distances and plot them as vertical segments.

High values are associated to high influence within the model.

Value

Doesn't return a value, called for side effects.

Author(s)

Giuseppe Reale

Examples

1
2
3
4
data("mtcars")
mod <- glm(mpg ~ cyl + hp + carb, family = Gamma, data = mtcars)
inf <- influenceDiag(mod)
cookDist(inf, label.id = rownames(mtcars))

glmxdiag documentation built on Jan. 10, 2022, 9:07 a.m.

Related to cookDist in glmxdiag...