title: colouring plot by factor using custom colours in r
body: <p>I am trying to make a scatter plot coloured by factor. I am using the following code:</p>
  
  <pre><code>data&lt;-iris
  plot(data$Sepal.Length, data$Sepal.Width, col=data$Species)
  </code></pre>
  
  <p>Is there anyway I can colour by the species factor but specify my own custom colours? Having a look around on Google it seems it is possible to do using ggplot2 but I have never used it and was hoping I could do this using the basic R functions. </p>
  
  <p>Any help would be greatly appreciated! </p>