setSVM: Create setting for SVM with python

Description Usage Arguments Examples

View source: R/SVM.R

Description

Create setting for SVM with python

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
setSVM(
  kernel = "rbf",
  C = c(1, 0.9, 2, 0.1),
  degree = c(1, 3, 5),
  gamma = c(1e-04, 3e-05, 0.001, 0.01, 0.25),
  shrinking = T,
  coef0 = 0,
  classWeight = T,
  seed = NULL
)

Arguments

C

penalty parameter C of the error term.

degree

degree of kernel function is significant only in poly, rbf, sigmoid

gamma

kernel coefficient for rbf and poly, by default 1/n_features will be taken.

shrinking

wether to use the shrinking heuristic.

coef0

independent term in kernel function. It is only significant in poly/sigmoid.

classWeight

Class weight based on imbalance

seed

A seed for the model

kernal

Specifies the kernel type to be used in the algorithm. one of ‘linear’, ‘poly’, ‘rbf’, ‘sigmoid’, ‘precomputed’. If none is given ‘rbf’ will be used.

Examples

1
2
3
4
## Not run: 
model.svm <- setSVM(kernel='rbf', seed = NULL)

## End(Not run)

hxia/plp-git-demo documentation built on March 19, 2021, 1:54 a.m.