R equation for svm regression from e1071 (eps-regression, radial kernel) to reproduce prediction results manually -




i trying reproduce prediction result svm regression package e1071 in r.

this post asked similar question answer not question.

this post explained how reproduce prediction mannually svm classification.

this post answered question i'm not sure how modify multivariate situations. method in post applies when have 1 variate/feature. needs set scale false.

so example:

library(e1071) library(plyr)  data(iris) iris$species <- mapvalues(iris$species, c("setosa", "versicolor", "virginica"), c(0, 50, 100)) iris$species <- as.numeric(as.character(iris$species)) # convert class (species) numeric numbers regression.  set.seed(1) fit <- svm(species ~., iris[,c(1,2,5)]) pred <- predict(fit, irisiris[,c(1,2)]) pred[1:4] #        1         2         3         4 #-3.874870  6.890615 -4.082644 -2.774084 

how calculate predictions mannually stored in pred? thanks!





wiki

Comments

Popular posts from this blog

elasticsearch - what is the equivalent data type for geo_point in hibernate search? -

firebase - How to wait value in Ionic 2 -

Jenkins: find build number for git commit -