Aan de slagGa gratis aan de slag

Linear SVM for complex dataset

In this exercise you will build a default cost linear SVM for the complex dataset you created in the first lesson of this chapter. You will also calculate the training and test accuracies and plot the classification boundary against the test dataset. The e1071 library has been loaded, and test and training datasets have been created for you and are available in the data frames trainset and testset.

Deze oefening maakt deel uit van de cursus

Support Vector Machines in R

Cursus bekijken

Praktische interactieve oefening

Probeer deze oefening eens door deze voorbeeldcode in te vullen.

#build model
svm_model<- 
    svm(y ~ ., data = ___, type = "C-classification", 
        kernel = ___)
Code bewerken en uitvoeren