title: xyplot how to swap the default colour
body: <p>I have a dataframe called <strong>df</strong></p>
  
  <pre><code> clust    gender    conf    chall
     1        F        2        6
     2        M        4        1
     1        M        5        2
     1        F        3        5
     3        F        3        4
  </code></pre>
  
  <p>I want to make an xyplot from the <strong>lattic</strong> package as below:</p>
  
  <pre><code>xyplot(chall ~ conf, 
     data = df,
     group = gender, 
     auto.key = list(space = 'right'),
     jitter.x = T, jitter.y = T)
  </code></pre>
  
  <p>The problem is that the default colour assigns 'Blue' to females and 'Pink' to males. I just want to swap these colours. I understand it might be a basic question but I am unable to find a solution to this.</p>
  
  <p>The SO posts that I looked at, were for more advanced changes in plot settings and were not useful to me:</p>
  
  <ol>
  <li><p><a href="https://stackoverflow.com/questions/15908188/how-can-i-change-the-color-of-the-header-in-a-xyplot">How can I change the color of the header in a xyplot?</a></p></li>
  <li><p><a href="https://stackoverflow.com/questions/8536239/change-background-and-text-of-strips-associated-to-multiple-panels-in-r-lattic/8537752#8537752">change background and text of strips associated to multiple panels in R / lattice</a></p></li>
  <li><p><a href="https://stackoverflow.com/questions/24283828/assigning-colours-to-plots-in-lattice-according-to-set-or-factor-not-groups">assigning colours to plots in lattice according to Set or factor, not groups</a></p></li>
  <li><p><a href="https://stackoverflow.com/questions/18329837/change-default-colour-lines-xyplot-with-referencing">Change default colour lines xyplot with referencing</a></p></li>
  </ol>
  
  <p>Any help on this would be highly appreciated.</p>
  
  <p>For convenience, the dput(df):</p>
  
  <pre><code>dput(df)
      structure(list(clust = structure(c(1L, 2L, 1L, 1L, 3L), 
      .Label = c("1", "2", "3"), class = "factor"), 
      gender = c("F", "M", "M", "F", "F"), 
      conf = c(2L, 4L, 5L, 3L, 3L), 
      chall = c(6L, 1L, 2L, 5L, 4L)), 
      row.names = c(NA, 5L), class = "data.frame")
  </code></pre>