Cross validation in Support vector machine (SVM).

2 ビュー (過去 30 日間)
Max
Max 2015 年 1 月 27 日
Hello all,
I am trying to find out of sample mis-classification for my SVM model using by using:
CVSVMModel1 = crossval(SVMModel1);
misclass1 = kfoldLoss(CVSVMModel1);
This is from the link
http://www.mathworks.com/help/stats/support-vector-machines-svm.html#bsr5o09
However, I keep getting error as below:
Error using crossval (line 160)
At least two inputs are needed.
Since I just simply copied the codes from the link above, I assume the problem is perhaps due to MATLAB version! There was other errors that I had to use "svmtrain" instead of "fitcsvm". My MATLAB version is 2013b. Has anybody encountered similar problem? Could anybody give me a hint how to cross validate and finally get the out-of-sample mis-classification rate (please refer to the link above) on the trained ?

回答 (0 件)

カテゴリ

Help Center および File ExchangeDownloads についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by