How do the coefficient estimates from the usual rule

Assignment Help Engineering Mathematics
Reference no: EM131446643

1. This exercise revisits the Hitters data set.

(a) The glmnet() function, by default, internally scales the predictor variables so that they will have standard deviation 1, before solving the ridge regression or lasso problems. This is a result of its default setting standardize=TRUE. Explain why such scaling is appropriate for this application.

(b) Verify that, for a very small value of λ, both the ridge regression and lasso estimates are very close to the least squares estimates. Also verify that, for a very large value of λ, both the ridge regression and lasso estimates approach 0 in all components (except the intercept, which is not penalized by default).

(c) An alternative method for selecting the tuning parameter λ is to use the one-standard-error rule. Under this rule, instead of choosing λ to minimize test MSE, the largest value of λ for which the test MSE is within one standard error of the minimum is chosen. Provide a rationale for the one-standard-error rule.

(d) For each of the ridge regression and lasso models corresponding to the grid of λ values defined in the notes, perform 5-fold cross-validation to determine the best value of λ. Report the results from both the usual minimum MSE rule, and the one-standard-error rule for choosing λ. Note that the cv.glmnet() returns the value of λ selected using the one standard-error rule under the name lambda.1se.

(e) From the last part, you should have computed 4 values of the tuning parameter:

λridgemin , λridge1se , λlassomin , λlasso1se

These are the results of running 5-fold cross-validation on each of the ridge and lasso models, and using the usual rule (min) or the one-standard-error rule (1se) to select λ. Now, using the predict() function, with type="coef", report the coefficient estimates at the appropriate values of λ. That is, you will report two coefficient vectors coming from ridge regression with λ = λridgemin and λ = λridge1se , and likewise for the lasso. How do the coefficient estimates from the usual rule compare to those from the one standard error rule? How do the ridge estimates compare to those from the lasso?

(f) Suppose that you were coaching a young baseball player who wanted to strike it rich in the major leagues. What handful of attributes would you tell this player to focus on?

2. Predic the number of applications received (Apps) using the other variables in the College data set, which is available in the ISLR library.

(a) Use ?College to access information about the data set and answer the following questions. Note that you may also find the summary() function useful.

i. Not including Apps, how many variables are in the data set? In other words, what is p?

ii. Are there any missing values in the data set? If so, remove them.

iii. What is the sample size (once missing values have been removed, if necessary)? In other words, what is N?

iv. Are there any qualitative variables in the data set? If so, list them.

(b) Split the data set into a training set and a test set.

(c) Fit a linear model using least squares on the training set and report the test error obtained.

(d) Fit a ridge regression model on the training set, with λ chosen by cross-validation. Report the test error obtained.

(e) Fit a lasso model on the training set, with λ chosen by cross-validation. Report the test error obtained, along with the number of non-zero coefficient estimates.

(f) Comment on the results obtained. How accurately can we predict the number of college applications received? Is there much difference among the test errors resulting from these three approaches?

Reference no: EM131446643

Questions Cloud

How does my conclusion address the complexities of the issue : How can I validate the accuracy of my statement? How is this information relevant? How does my conclusion address the complexities of the issue? What is another interpretation or viewpoint of the issue?
Which need the most emphasis and directed efforts : The Department of Homeland Security (or DHS) regularly publishes a list of strategic challenges to national security in the United States. The challenges are aspects of their mission in which need the most emphasis and directed efforts.
How is tobacco depicted culturally : The purpose of the paper is to gain and in depth understanding of tobacco based on biological, pharmacological, and psychological information. Then use the information to examine social perceptions. FACTS about tobacco, it's properties and it's u..
Daimler-chrysler group : Assuming that Daimler-Chrysler group needs to cover its expenses in Korea and thus wants to hedge its won exposure using a forward contract with a US bank in Korea, what is the minimum amount of won they should receive on August 30th, 2007 given t..
How do the coefficient estimates from the usual rule : These are the results of running 5-fold cross-validation on each of the ridge and lasso models, and using the usual rule (min) or the one-standard-error rule (1se) to select λ. How do the coefficient estimates from the usual rule compare to those ..
Review the vargas family case study : Review the available literature regarding the sustainability of solution-focused therapy. Write a 350-500-word Op-ed article with your thoughts and argue for or against the use of brief therapy. Support your argument with at least two academic re..
What are component that contribute to port security planning : What are the components that contribute to port security planning. Why are they important and what aspects of security planning are considered in port facility operations?
Why cultural differences is important : In business, recognizing cultural differences is important because a. Doing so helps reduce the chances for misunderstanding b. Someone from another culture may try to take advantage of your ignorance.
Organize and develop the three parts : Ensure that your PowerPoint presentation fulfills the appropriate length requirements and professional style requirements - Include a title slide containing the title of the assignment, your name, the professor's name, the course title, and the date..

Reviews

len1446643

3/31/2017 8:34:20 AM

Please see attached document. You will need to use data set Hitters for problem 1 and data set college for problem 2 both data sets are available in ISLR library in R/RSTUDIO. Please provide solution in MS Word format.

Write a Review

Engineering Mathematics Questions & Answers

  Develop a plan for purchasing and cleaning

Mary's major at State is Management Science and she wants to develop a plan for purchasing and cleaning sheets using Linear Programming. Help Mary formulate a Linear Programming Nodel for this problem and solve it using the computer.

  Solve differential equation using galerkin method

Solve differential equation of d 2 h /dx 2 =0 using the Galerkin method and considering 0 ≤ x ≤ 3 given that: h = 0 cm when x = 0 m and h = 10 cm when x = 3 m .

  Observed differences over time are important

How can you or your department decide whether or not the observed differences over time are important? How could using a mean difference test help?

  Problems resulting in bad publicity for the company

This STEEPLE and Balance sheet needs to be completed based on the company has been having with ship reliability and passenger safety. Because of recent problems resulting in bad publicity for the company , the Team has been asked to provide proces..

  Calculate and interpret the profit variance

Calculate and interpret the profit variance and calculate and interpret the revenue variance - How are the variances calculated above related?

  Wirte a correct alternative hypothesis

What differentiates a Z test statistic for a population from the z statistic for sampling of the mean? Why difference. Consider a normal population

  Give optimal no-arbitrage bounds on a call option struck

Give optimal no-arbitrage bounds on a call option struck at 100. If the call option struck at 100 is worth 5, give optimal no-arbitrage bounds on a call option struck at 110.

  Explain about natural growth model

How long will it take before it is considered dangerous to live in this mountain valley - atmospheric pollutants in a certain mountain valley grown according to a natural growth model

  Analyze the goodness of fit of each model

Analyze the goodness of fit of each model M by computing the likelihood for each model, based on the predefined regression coefficients, b provided in INPUT.mat (also listed in Table 2 for each model in appendix, see more detail in appendix)

  Q1 the bending moment m of a beam of length l is given

q.1 the bending moment m of a beam of length l is given bydmdx wx1where w is the load constant. if m0 0 find m as a

  What is the density of the unknown liquid

When the rock is totally inunersed in water, the tension is 28.4 N. When the rock is totally inunersed in an unknown liquid, the tension is 18.6 N. What is the density of the unknown liquid?

  Indicate the polarity by proper placement of the symbols

Draw structural formulas for all possible isomers having the following molecular formulas

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd