Open kovacu opened 6 years ago
Point (g): The selected train data (train = (year%%2 == 0) ) leads to optimal KNN solution with k = 3. Test error in this case amounts to 13.7 %. #######
knn.pred = knn(train.X, test.X, train.mpg01, k = 3) mean(knn.pred != mpg01.test) [1] 0.1373626 #######
Point (g): The selected train data (train = (year%%2 == 0) ) leads to optimal KNN solution with k = 3. Test error in this case amounts to 13.7 %. #######