title: creating a 2D plot in R with KSVM (kernlab) with 3 or more class variables
body: <p>I am trying to create a 2D plot using SVM in library(kernlab), but it appears the plot function 
  is only appropriate for binary classification. I would like to be able to plot 3 (or more) groups, as in the example below.</p>
  
  <p>My data is structured just like the iris data, so I will use it to illustrate. </p>
  
  <p>After fitting the model:</p>
  
  <pre><code> fit.ksvm &lt;- ksvm(Species~., data=iris, kernel= "rbfdot", prob.model=TRUE)
   fit.ksvm
  </code></pre>
  
  <p>I use the plot function for ksvm:</p>
  
  <pre><code>plot(fit.ksvm, data=iris)
  </code></pre>
  
  <p>and get the message following:</p>
  
  <pre><code>&gt; plot(fit.ksvm, data=iris)
    Error in .local(x, ...) : 
    plot function only supports binary classification
  </code></pre>
  
  <p>When I try similar analyses using a two-way classification, the plot is produced. So, I think the issue is multiple groups. Can anyone think of a way to create a two-dimensional "heat-map" similar to the one below, but using an SVM classification model with three (or more?) classes?</p>
  
  <pre><code>two-way SVM classification
  x &lt;- rbind(matrix(rnorm(120),,2),matrix(rnorm(120,mean=3),,2))
  y &lt;- matrix(c(rep(1,60),rep(-1,60)))
  
  svp &lt;- ksvm(x,y,type="C-svc")
  plot(svp,data=x)
  </code></pre>