What is the right formula for the RBF 'KernelScale' of fitcsvm?
Afficher commentaires plus anciens
RBF kernel function is defined as exp(-1/(2*sigma^2) ....
The option 'KernelScale' of the Matlab function fitcsvm, does it refer to sigma, sigma^2, 2*sigma^2, or sqrt(2)*sigma ?
Réponse acceptée
Plus de réponses (1)
The RBF (Gaussian) kernel can be defined with either gamma or sigma:
or
where sigma is the standard deviation of the Gaussian distribution.
According to the fitcsvm documentation, instead of using sigma or gamma, the prediction data is simply divided by KernelScale before training, and
Therefore,
KernelScale = 1/sqrt(gamma)
as clarified by MathWorks staff here:
And:
KernelScale = sqrt(2) * sigma
Catégories
En savoir plus sur Classification dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
