Description Usage Arguments Value Examples
This function predicts the species of penguins based on the input data.
1 | my_knn_cv(train, cl, k_nn, k_cv)
|
train |
The data frame inputted. |
cl |
The true class of the training data. |
k_nn |
Numeric input representing the number of neighbors. |
k_cv |
Numeric input representing the number of folds. |
A list with a vector of predicted classes and a numeric value with the predicted misclassification rate.
1 2 | my_knn_cv(data_use, data_clean$species, k_nn = 1, k_cv = 5)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.