SVM classification with custom kernel

I am using an SVM (SVM_train, Bioinformatics toolbox) to classify data, and I would like to have my final trained SVM models with different kernel functions. I didn't understand how to specify my own kernel maps: if I would like to use a Cauchy kernel defined as
k=(1/(1+(|u-v|^2/sigma))
where u,v are the vectors of the X data, and sigma is the parameter defined by the user (sigma=2.5).
Matlab gives me a warning message: Error using ==> svmtrain at 453 Error calculating the kernel function: Matrix dimensions must agree.
I do not understand where is my mistake. If you can help me I really appreciate.
Thank you!

답변 (0개)

카테고리

도움말 센터File Exchange에서 Statistics and Machine Learning Toolbox에 대해 자세히 알아보기

태그

질문:

2014년 10월 4일

Community Treasure Hunt

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

Start Hunting!

Translated by