title: Select columns in data.table based on logical vector
body: <p>Let's say I have the following data.frame and the following data.table:</p>
  
  <pre><code>DF = data.frame(x=rep(c("a","b","c"),each=3), y=c(1,3,6), v=1:9)
  DT = data.table(x=rep(c("a","b","c"),each=3), y=c(1,3,6), v=1:9)
  </code></pre>
  
  <p>With a data.frame, I can select columns based on a logical vector as follows:</p>
  
  <pre><code>DF[,c(TRUE,TRUE,FALSE)]
  </code></pre>
  
  <p>The result is:</p>
  
  <pre><code>  x y
  1 a 1
  2 a 3
  3 a 6
  4 b 1
  5 b 3
  6 b 6
  7 c 1
  8 c 3
  9 c 6
  </code></pre>
  
  <p>However</p>
  
  <pre><code>DT[,c(TRUE,TRUE,FALSE)]
  </code></pre>
  
  <p>leads to:</p>
  
  <pre><code>[1]  TRUE  TRUE FALSE
  </code></pre>
  
  <p>How can it be done?</p>