gvif.lm: Generalized Variance Inflation Factor

View source: R/glms.R

gvif.lmR Documentation

Generalized Variance Inflation Factor

Description

Computes the generalized variance inflation factor (GVIF) for a weighted or unweighted normal linear model.

Usage

## S3 method for class 'lm'
gvif(model, verbose = TRUE, ...)

Arguments

model

an object of the class lm.

verbose

an (optional) logical switch indicating if should the report of results be printed. By default, verbose is set to be TRUE.

...

further arguments passed to or from other methods.

Details

If the number of degrees of freedom is 1 then the GVIF reduces to the Variance Inflation Factor (VIF).

Value

A matrix with so many rows as effects in the model and the following columns:

GVIF the values of GVIF,
df the number of degrees of freedom,
GVIF^(1/(2*df)) the values of GVIF^{1/2 df},

References

Fox J., Monette G. (1992) Generalized collinearity diagnostics, JASA 87, 178–183.

See Also

gvif.glm

Examples

###### Example 1: New York air quality measurements
fit1 <- lm(log(Ozone) ~ Solar.R + Temp + Wind, data=airquality)
gvif(fit1)

###### Example 2: Fuel consumption of automobiles
fit2 <- lm(mpg ~ log(hp) + log(wt) + qsec, data=mtcars)
gvif(fit2)

###### Example 3: Credit card balance
Credit <- ISLR::Credit
fit3 <- lm(Balance ~ Cards + Age + Rating + Income + Student + Limit, data=Credit)
gvif(fit3)

glmtoolbox documentation built on Oct. 10, 2023, 9:06 a.m.