Northeastern University Ridge and LASSO Functions Report

User Generated

Envanyl

Programming

Northeastern University

Description

In order to consolidate your theoretical knowledge into technique and skills with practical and applicational value, you will use the glmnet() package in R to implement Ridge and LASSO functions to build linear and logistic models through Ridge and LASSO regression over values of the regularization parameter lambda.

Unformatted Attachment Preview

Assignment Summary Use the College dataset c from the ISLR library to build regularization models by using Ridge and Lasso (least absolute shrinkage and selection operator). Predict Grad.Rate for all models. 1. Split the data into a train and test set - refer to the Feature Selection_R.pdf document for information on how to split a dataset. Ridge Regression 2. Use the cv.glmnet function to estimate the lambda.min and lambda.1se values. Compare and discuss the values. 3. Plot the results from the cv.glmnet function provide an interpretation. What does this plot tell us? 4. Fit a Ridge regression model against the training set and report on the coefficients. Is there anything interesting? 5. Determine the performance of the fit model against the training set by calculating the root mean square error (RMSE). sqrt(mean((actual - predicted)^2)) 6. Determine the performance of the fit model against the test set by calculating the root mean square error (RMSE). Is your model overfit? LASSO 7. Use the cv.glmnet function to estimate the lambda.min and lambda. 1se values. Compare and discuss the values. 8. Plot the results from the cv.glmnet function provide an interpretation. What does this plot tell us? 9. Fit a LASSO regression model against the training set and report on the coefficients. Do any coefficients reduce to zero? If so, which ones? 10. Determine the performance of the fit model against the training set by calculating the root mean square error (RMSE). sqrt(mean((actual - predicted)^2)) 11. Determine the performance of the fit model against the test set by calculating the root mean square error (RMSE). Is your model overfit? Comparison 12. Which model performed better and why? Is that what you expected? 13. Refer to the Intermediate_Analytics_Feature_Selection_R.pdf document for how to perform stepwise selection and then fit a model. Did this model perform better or as well as Ridge regression or LASSO? Which method do you prefer and why?
Purchase answer to see full attachment
User generated content is uploaded by users for the purposes of learning and should be used following Studypool's honor code & terms of service.

Explanation & Answer

Hello...


Anonymous
Really helped me to better understand my coursework. Super recommended.

Studypool
4.7
Trustpilot
4.5
Sitejabber
4.4

Related Tags