Fork me on GitHub

This documentation is for scikit-learn version 0.18.dev0Other versions

If you use the software, please consider citing scikit-learn.

sklearn.svm.libsvm.cross_validation

sklearn.svm.libsvm.cross_validation()

Binding of the cross-validation routine (low-level routine)

Parameters:

X: array-like, dtype=float, size=[n_samples, n_features] :

Y: array, dtype=float, size=[n_samples] :

target vector

svm_type : {0, 1, 2, 3, 4}

Type of SVM: C SVC, nu SVC, one class, epsilon SVR, nu SVR

kernel : {‘linear’, ‘rbf’, ‘poly’, ‘sigmoid’, ‘precomputed’}

Kernel to use in the model: linear, polynomial, RBF, sigmoid or precomputed.

degree : int

Degree of the polynomial kernel (only relevant if kernel is set to polynomial)

gamma : float

Gamma parameter in RBF kernel (only relevant if kernel is set to RBF)

coef0 : float

Independent parameter in poly/sigmoid kernel.

tol : float

Stopping criteria.

C : float

C parameter in C-Support Vector Classification

nu : float

cache_size : float

random_seed : int, optional

Seed for the random number generator used for probability estimates. 0 by default.

Returns:

target : array, float

Previous