a formula, with a response but no interaction terms. For the case of data frame, it is taken as the model frame (see model.frame).
train
data frame or matrix of train set cases.
test
data frame or matrix of test set cases.
k.max
the maximum number of number of neighbours to consider, must be at least two.
transform
a character with options FALSE (default), "minmax", and "zscore".
Option "minmax" means no transformation. This option allows the users to use normalized version of the train and test sets for the kNN aglorithm.
set.seed
a single value, interpreted as an integer, or NULL.
…
options to be passed to kNN().
References
Ripley, B. D. (1996)
Pattern Recognition and Neural Networks. Cambridge.
Venables, W. N. and Ripley, B. D. (2002)
Modern Applied Statistics with S. Fourth edition. Springer.