Description Usage Arguments Value
k-nearest neighbor cross-validatory classification from training set.
1 | my_knn_cv(train, cl, k_nn, k_cv)
|
train |
input data frame. |
cl |
true class value of your training data. |
k_nn |
integer representing the number of neighbors. |
k_cv |
integer representing the number of folds. |
a list with objects class
, a vector of the predicted class
for all observations, and cv_err
, a numeric with the
cross-validation misclassification error.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.