How to use predict function in matlab to test mutli-class SVM -
i want implement 10 fold cross-validation in multi-class svm using matlab built-in functions. i've used code this answer , replaced training function svmtrain , testing part following code:
for j=1: size(testdata,1) found=0; k=1:numlabels if(svmclassify(model{k},testdata(j,:))) result(j) = k; found=1; break; end end if(found==0) %not classified result(j) = -1; end
however, faced problem data not classified because svmclassify returned 0 iterations. thus, want use predict function can pick label maximum score. can please me implement it.
Comments
Post a Comment