library(lattice)
xyplot(Petal.Length ~ Petal.Width, data = iris, groups = Species, auto.key=list(corner=c(1,0)))
data("iris")
attach(iris)
subdata<-iris[iris$Species != 'virginica',]
subdata$Species<-factor(subdata$Species)
library(e1071)
model1<-svm(Species ~ Petal.Length+Petal.Width,data=subdata)
plot(model1, subdata, Petal.Length ~ Petal.Width)