In: Statistics and Probability
[USING R & dataset “Boston”] Using the leave-one-out cross-validation and 5-fold cross-validation techniques to compare the performance of models in (a) and (b) with:
(a) SalesPredict <- lm(Sales ~ Price + Urban + US, data = Carseats)
(b) SalesRevise <- lm(Sales ~ Price + US, data = Carseats)
Hint: Functions update (with option subset) and predict.
When Use method LOOVC(Leave one out cross validation) and 5-fold Cross Validation.
5-fold Cross Validation gives more Rsquare value comparison to LOOVC method.
According to anlaysis 5-Fold Cross Validation is good from LOOVC method.