thank you for this code, it great ; but i have an error when i try to change the kernel function. The error is " Error using ==> seqminopt>seqminoptImpl at 203
No convergence achieved within maximum number of iterations.
Error in ==> seqminopt at 84
[alphas offset] = seqminoptImpl(data, targetLabels, ...
Error in ==> svmtrain at 541
[alpha bias] = seqminopt(training, groupIndex, ...
Error in ==> multisvm at 49
svmStruct = svmtrain(T,newClass,'kernel_function','linear' ); %
I am using rbf kernel function, you must change it also
Error in ==> teststa at 61
[itrfin] = multisvm( data,classa,test )"
Hi.Thanks for your implementation but I think it is incorrect. When you return 0 or 1 from svmclassify, you maybe have several zeros or ones with different classes!!!
I think you need to compute the real values(before execute sign function) and assign the test data to the class which has the biggest positive ouput.
25 Oct 2013
Multi Class SVM
Model and classify training/test data sets into more than 2 classes with SVM.