powered by
Extract K-nearest neighbor model parameters from a knn3 object created by the caret library
# S3 method for knn3 extract_params(object, ...)
an object of class "knn3"
further arguments passed to or from other methods
PFA as a list-of-lists that can be inserted into a cell or pool
iris2 <- iris colnames(iris2) <- gsub('\\.', '_', colnames(iris2)) model <- caret::knn3(Species ~ ., iris2) extracted_params <- extract_params(model)
Run the code above in your browser using DataLab