title: Get column index from label in a data frame
body: <p>Say we have the following data frame:</p>
  
  <pre><code>&gt; df
    A B C
  1 1 2 3
  2 4 5 6
  3 7 8 9
  </code></pre>
  
  <p>We can select column 'B' from its index:</p>
  
  <pre><code>&gt; df[,2]
  [1] 2 5 8
  </code></pre>
  
  <p>Is there a way to get the index (2) from the column label ('B')?</p>