I know that knn.cv(train=predictors.training, cl=classes.training, k=3, prob=TRUE) works but by doing so I fix the tuning paramer k to be 3. Isn't cross validation a technique to choose the optimal tuning parameter trying a range of different values for the tuning parameter?
-- View this message in context: http://r.789695.n4.nabble.com/k-nearest-neighbour-classification-tp4713523p4713531.html Sent from the R help mailing list archive at Nabble.com. ______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.