title: extract information from a data frame parametrically (via a menu selection)
body: <p>I would like to extract information from a data frame parametrically.
  That is:</p>
  
  <pre><code>A &lt;- c(3, 10, 20, 30, 40)
  B &lt;- c(30, 100, 200, 300, 400)
  DF &lt;- data.frame(A, B)
  
  DF[A%in%c(1, 2, 3, 4, 5), ] # it works
  
  # But what if this is the case,
  # which comes for example out of a user-menu selection:
  m &lt;- "A%in%"
  k &lt;- c(1, 2, 3, 4, 5)
  
  # How can we make something like that work:
  DF[eval(parse(text=c(m, k))), ]
  </code></pre>