How to get result for each k-fold cross validation
Show older comments
The function crossval returns the partitioned model and 10 trained models for a 10-fold cross validation, and kfoldloss calculates the loss. However, I want to see the accuracy of each trained models within the partitioned model, what should I do?
Answers (1)
ayca firtin
on 8 Jun 2022
0 votes
SVM = fitcsvm(X,y,'KernelFunction', 'rbf', 'Standardize',true,'KernelScale', 'auto') ;
CVS = crossval(SVM);
classLoss = kfoldLoss(CVS, 'Mode', 'individual')
Categories
Find more on Classification Trees in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!