calc_VIF: Calculate variance inflation factors for regression model...

calc_VIFR Documentation

Calculate variance inflation factors for regression model parameters

Description

Computes variance inflation factors from the covariance matrix of parameter estimates, using the method of Davis et al. (1986), which is based on the correlation matrix from the information matrix.

Usage

calc_VIF(mod)

Arguments

mod

a model object created by lm, glm, lmer, glmer

Details

Adapted from vif in the rms package.

Value

a vector of VIFs

Author(s)

Frank Harrell; Jason Grafmiller

References

Davis CE, Hyde JE, Bangdiwala SI, Nelson JJ: An example of dependencies among variables in a conditional logistic regression. In Modern Statistical Methods in Chronic Disease Epidemiology, Eds SH Moolgavkar and RL Prentice, pp. 140–147. New York: Wiley; 1986.

Examples

## Not run: 
set.seed(1)
x1 <- rnorm(100)
x2 <- x1+.1*rnorm(100)
x3 <- x2 + .5*rnorm(100)
y  <- sample(0:1, 100, TRUE)
f  <- glm(y ~ x1 + x2 + x3, family = binomial)
calc_VIF(f)

## End(Not run)

jasongraf1/VADIS documentation built on July 19, 2023, 10:26 p.m.