title: Find rows in a data frame where two columns are equal
body: <p>I'd like to select the rows in a data frame where two columns, A and B are equal. I have tried this:</p>
  
  <pre><code>A &lt;- c(0,1,2)
  B &lt;- c(2,1.000001,0)
  df &lt;- as.data.frame(cbind(A,B))
  subset(df,A==B) # does not work
  # [1] A B
  # &lt;0 rows&gt; (or 0-length row.names)
  subset(df,round(A,3)==round(B,3)) # does work
  #  A        B
  # 2 1 1.000001
  subset(df,A==B)
  </code></pre>