title: Subset and ggplot2
body: <p>I have a problem to plot a subset of a data frame with ggplot2. My df is like:</p>
  <pre class="lang-r prettyprint-override"><code>df = data.frame(ID = c('P1', 'P1', 'P2', 'P2', 'P3', 'P3'),
                  Value1 = c(100, 120, 300, 400, 130, 140),
                  Value2 = c(12, 13, 11, 16, 15, 12))
  </code></pre>
  <p>How can I now plot <code>Value1</code> vs <code>Value2</code> only for <code>ID</code>s <code>'P1'</code> and <code>'P3'</code>?
  For example I tried:</p>
  <pre class="lang-r prettyprint-override"><code>ggplot(subset(df,ID==&quot;P1 &amp; P3&quot;) +
    geom_line(aes(Value1, Value2, group=ID, colour=ID)))
  </code></pre>
  <p>but I always receive an error.</p>