Question 4: Bike Data – Prediction (4a) 2 pts – Predict bike…
Question 4: Bike Data – Prediction (4a) 2 pts – Predict bikes for the test set (bike_data_test) using model1. Display the first six predicted values. (4b) 2.5 pts – Calculate and display the mean squared prediction error (MSPE) for model1. List one limitation of using this metric to evaluate prediction accuracy. (4c) 1 pt – Refit model1 on bike_data_full, and call it model2. Display the summary table for the model. (4c.1) 3 pts – Estimate the 10-fold and leave-one-out cross validation mean prediction squared error (MSPE) for model2. Display these values. Hint: cv.glm() from the boot package uses MSPE as the default cost function. (4c.2) 1 pt – How do these two MSPEs compare to the model1 MSPE from 4b?
Read Details