I applied some data to find the best variables solution of regression model using ridge regression in R. I have used lm.ridge
and glmnet
(when alpha=0
), but the results are very different especially when lambda=0
. It suppose that both parameter estimators have the same values. So, what is the problem here?
best regards
Solved – Ridge regression results different in using lm.ridge and glmnet
glmnetrregressionridge regression
Best Answer
glmnet standardizes the y variable and uses the mean squared errors instead of sum of squared errors. So you need to make the appropriate adjustments to match their outputs.