Question: Cross Validation assignment Use the Boston data for regression cross validation and Weekly data for the Classification cross validation. i.e. implement lines 1-76 on the

Cross Validation assignment

Use the Boston data for regression cross validation and Weekly data for the Classification cross validation.

i.e. implement lines 1-76 on the Boston dataset from MASS. Dependent variable medv, run a non-linear model with lstat or another variable of your choice. When you are doing the validation set approach, split Training Test at 70/30. To figure out how much should be in the training use dim command to see the number of observations. Then train command will be Train(Total observations, Training observations), line 8.

Lines 77 through 125 are on Classification models. Use Weekly data from ISLR2 for this part of the code, use Direction as the dependent variable.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Finance Questions!