CBPLinearE {CBPE} | R Documentation |
Correlation-based Estimator for Linear Regression Models
Description
This function computes the correlation-based estimator for linear regression models.
Usage
CBPLinearE(X, y, lambda)
Arguments
X |
A numeric matrix of predictors where rows represent observations and columns represent variables. |
y |
A numeric vector of response variables. |
lambda |
A regularization parameter. |
Details
The correlation-based penalized linear estimator is calculated as:
where denotes the (empirical) correlation between the
th and the
th predictor.
Value
A numeric vector of the estimated coefficients for the specified model.
References
Tutz, G., Ulbricht, J. (2009). Penalized regression with correlation-based penalty. Stat Comput 19, 239–253.
Examples
set.seed(42)
n <- 100
p <- 4
X <- matrix(rnorm(n * p), n, p)
beta_true <- c(0.5, -1, 2, 5)
y <- X %*% beta_true + rnorm(n)
lambda <- 0.1
result <- CBPLinearE(X, y, lambda = lambda)
print(result)
[Package CBPE version 0.1.0 Index]