# Run a quick Support Vector Machine to predict the iris species.
# depends: (caret)
SimpleExample<-function(Data){
ctrl <- caret::trainControl(method = "cv", savePred=T, classProb=T)
mod <- caret::train(Data[,1]~., data=Data, method = "svmLinear", trControl = ctrl)
return(mod)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.