Effacer les filtres
Effacer les filtres

A X B Cross-validation.

1 vue (au cours des 30 derniers jours)
Basheer Alwaely
Basheer Alwaely le 25 Nov 2018
How to implement A X B Cross-validation and get the confusion matrix. For example, 5 times 2-fold Cross-validation.
I used this code to implement k-fold only
mdl = fitcknn(inputs,targets);
partModel = crossval(mdl, 'KFold', 5); % 5-fold cross validation
Accuracy = 1 - kfoldLoss(partModel, 'LossFun', 'ClassifError');
[validationPredictions, ~] = kfoldPredict(partModel);
Conf_Mat=confusionmat(targets',validationPredictions);

Réponses (0)

Catégories

En savoir plus sur Statistics and Machine Learning Toolbox dans Help Center et File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by