模型参数的筛选
最后发布时间:2022-03-23 17:17:14
浏览量:
KNN
train_kk <- train.kknn(group~.,
data=input,
kmax=100,
kernel = c("rectangular", "triangular",
"epanechnikov", "gaussian",
"rank", "optimal"))
best_kernel <- train_kk$best.parameters$kernel
best_k <- train_kk$best.parameters$k
ce_kk <- train_kk$MISCLASS
min_ce <- min(ce_kk)