omcdiag: Overall Multicollinearity Diagnostics Measures

Description Usage Arguments Details Value Note Author(s) References See Also Examples

View source: R/omcdiag.R

Description

Computes different overall measures of multicollinearity diagnostics for matrix of regressors. Overall measures of collinearity detection includes Determinant of the correlation matrix (Cooley and Lohnes, 1971), Farrar test of chi-square for presence of multicollinearity (Farrar and Glauber, 1967), Red Indicator (Kovacs et al., 2015) <doi: 10.1111/j.1751-5823.2005.tb00156.x>, Sum of lambda inverse Chatterjee and Price (1977) values, Theil's indicator (Theil, 1971) and condition number (Belsley et al., 1980) <doi: 10.1007/BF00426854> with or without intercept term.

Usage

1
2
omcdiag(mod, na.rm = TRUE, Inter = TRUE, detr = 0.01, red = 0.5,
                     conf = 0.95, theil = 0.5, cn = 30,...) 

Arguments

mod

A model object, not necessarily type lm

na.rm

Whether to remove missing observations.

Inter

Whether to include or exclude Intercept term, by default Inter=TRUE.

detr

Determinant default threshold, detr=0.01.

red

red indicator default threshold, red=0.5.

conf

confidence level of Farrar Chi-Square test, conf=0.95.

theil

Theil's indicator default threshold, theil=0.5.

cn

condition number default threshold, cn=30.

...

Extra argument(s) if used will be ignored.

Details

This function detects the existence of multicollinearity by using different available diagnostic measures already available in literature such as Determinant of correlation matrix, Farrar test of chi-square, Red Indicator, Sum of lambda inverse values, Theil's Indicator and Condition Number.

Function also displays diagnostic measures value with the decision of either multicollinearity is detected by the diagnostics or not. The Value of 1 indicate that multicollinearity is detected and 0 indicate measure could not detect by the certain diagnostic measure. A list object of class "omc" is returned:

Value

odiags

Listing of all overall diagnostic measures.

Inter

logical, if TRUE (the default value) condition number is returned with intercept term included.

x

matrix of regressors.

call

The matched call.

Note

Missing values in data will be removed by default. There is no method for the detection of multicollinearity, if missing values exists in the data set.

Author(s)

Muhammad Imdad Ullah, Muhammad Aslam

References

Belsely, D. A. A Guide to Using the Collinearity Diagnostics. Computer Science in Economics and Management, 4(1): 33–50, 1991.

Belsley, D. A., Kuh, E., and Welsch, R. E. Regression Diagnostics: Identifying Influential Data and Sources of Collinearity. John Wiley \& Sons, New York, 1980.

Chatterjee, S. and Hadi, A. S. Regression Analysis by Example. John Wiley \& Sons, 4th edition, New York, 2006.

Greene, W. H. Econometric Analysis. Prentice–Hall, Upper Saddle River, New Jersey, 4th edition, 2000.

Imdad, M. U. Addressing Linear Regression Models with Correlated Regressors: Some Package Development in R (Doctoral Thesis, Department of Statistics, Bahauddin Zakariya University, Multan, Pakistan), 2017.

Imdadullah, M., Aslam, M., and Altaf, S. mctest: An R Package for Detection of Collinearity Among Regressors. The R Journal, 8(2):499–509, 2016.

Kovacs, P., Petres, T., and Toth, L. A New Measure of Multicollinearity in Linear Regression Models. International Statistical Review / Revue Internationale de Statistique, 73(3): 405–412, 2005.

See Also

Individual collinearity diagnostic measure imcdiag, Eigenvalues and variance decomposition proportion eigprop

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
## Hald Cement data
data(Hald)
model <- lm(y~X1+X2+X3+X4, data = as.data.frame(Hald))

## all oveall diagnostic measures and eigenvalues with intercept
od<-omcdiag(model)

## all oveall diagnostic measures and eigenvalues without intercept
omcdiag(model, Inter=FALSE)

## all oveall diagnostic measures and eigenvalues with intercept
## with different determinant and confidence level threshold

omcdiag(model, detr=0.001, conf=0.99)

## returns the determinant of correlation matrix |X'X|
omcdiag(model)[1]

Example output

Call:
omcdiag(mod = model, Inter = FALSE)


Overall Multicollinearity Diagnostics

                       MC Results detection
Determinant |X'X|:         0.0011         1
Farrar Chi-Square:        67.2825         1
Red Indicator:             0.5414         1
Sum of Lambda Inverse:   622.3006         1
Theil's Method:            0.9981         1
Condition Number:          9.4325         0

1 --> COLLINEARITY is detected by the test 
0 --> COLLINEARITY is not detected by the test


Call:
omcdiag(mod = model, detr = 0.001, conf = 0.99)


Overall Multicollinearity Diagnostics

                       MC Results detection
Determinant |X'X|:         0.0011         0
Farrar Chi-Square:        67.2825         1
Red Indicator:             0.5414         1
Sum of Lambda Inverse:   622.3006         1
Theil's Method:            0.9981         1
Condition Number:        249.5783         1

1 --> COLLINEARITY is detected by the test 
0 --> COLLINEARITY is not detected by the test

$odiags
                          results detection
Determinant          1.067659e-03         1
Farrar Chi-Square    6.728248e+01         1
Red Indicator        5.413857e-01         1
sum of Lambda Invers 6.223006e+02         1
Theil Indicator      9.980901e-01         1
Condition Number     2.495783e+02         1

mctest documentation built on July 8, 2020, 6:55 p.m.