svm_plot_2d {structToolbox} | R Documentation |
Plots the training data and the SVM boundary. 2d data only (ncol(D$data)==2).
svm_plot_2d(factor_name, npoints = 100, ...)
factor_name |
The column of sample_meta to use |
npoints |
Used to control the resolution of the grid used to plot the boundary. Default 100. |
... |
additional slots and values passed to struct_class |
struct object
D = iris_DatasetExperiment() M = filter_smeta(mode='exclude',levels='setosa',factor_name='Species') + mean_centre()+PCA(number_components=2)+ SVM(factor_name='Species',kernel='linear') M = model_apply(M,D) C = svm_plot_2d(factor_name='Species') chart_plot(C,M[4],predicted(M[3]))