CreateDffitsPlot: CreateDffitsPlot

Description Usage Arguments

View source: R/CreateDffitsPlot.R

Description

Computes the DFFITS statstic for the fitted model, plots them, and optionally saves the to disk.

Usage

1
2
3
4
5
6
7
CreateDffitsPlot(
  fit,
  critical.value = NULL,
  return.inf = TRUE,
  dir = ".",
  save.plot = TRUE
)

Arguments

fit

lm object. Linear Model fit to the data. No default.

critical.value

Numeric vector of length 1. Plotted as a dashed line, as a indicator of influential points. Defaults to NULL, in which case the value is not plotted. If not NULL, the observations whose corresponding values exceed the critical value is labelled in the plot. Else, the observations with the top 3 highest values are labelled.

return.inf

Logical vector of length 1. If TRUE the points that are "influential" are returned. Depends on the critical.value param: If NULL, then the top three points are returned, and if not null then the points whose values exceed the critical.value is returned. Defaults to TRUE.

dir

Character vector of lenght 1. Directory in which to store the plot. Ignored if save.plot is FALSE. Defaults to "."

save.plot

Logical vector of length 1. If TRUE the DFFITS plot are saved to disk. Defaults to TRUE.


itslwg/regone documentation built on Oct. 14, 2021, 12:52 a.m.