determination: Determination coefficients

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

View source: R/determination.R

Description

Function produces determination coefficient for the provided data

Usage

1
2
3
determination(xreg, bruteforce = TRUE, ...)

determ(xreg, bruteforce = TRUE, ...)

Arguments

xreg

Data frame or a matrix, containing the exogenous variables.

bruteforce

If TRUE, then all the variables will be used for the regression construction (sink regression). If the number of observations is smaller than the number of series, the function will use stepwise function and select only meaningful variables. So the reported values will be based on stepwise regressions for each variable.

...

Other values passed to cor function.

Details

The function calculates determination coefficients (aka R^2) between all the provided variables. The higher the coefficient is, the higher the potential multicollinearity effect in the model with the variables will be. Coefficients of determination are connected directly to Variance Inflation Factor (VIF): VIF = 1 / (1 - determination). Arguably it is easier to interpret, because it is restricted with (0, 1) bounds. The multicollinearity can be considered as serious, when determination > 0.9 (which corresponds to VIF > 10).

See details in the vignette "Marketing analytics with greybox": vignette("maUsingGreybox","greybox")

Value

Function returns the vector of determination coefficients.

Author(s)

Ivan Svetunkov, [email protected]

See Also

cor, mcor, stepwise

Examples

1
2
3
4
5
### Simple example
xreg <- cbind(rnorm(100,10,3),rnorm(100,50,5))
xreg <- cbind(100+0.5*xreg[,1]-0.75*xreg[,2]+rnorm(100,0,3),xreg,rnorm(100,300,10))
colnames(xreg) <- c("x1","x2","x3","Noise")
determination(xreg)

greybox documentation built on Dec. 11, 2019, 1:08 a.m.