title: How to make a vector from columns of data.frame in R?
body: <p>here is the detailed description:
  A dataframe like:</p>
  
  <pre><code>name height weight  
  john   6     160    
  mike   6.2   155    
  jack   7     180
  </code></pre>
  
  <p>I want to make a new column which is the combination of the last two columns:</p>
  
  <pre><code>height_weight    
  c(6,160)    
  c(6.2,155)    
  c(7,180)
  </code></pre>
  
  <p>I think this is easy with for loops. I am trying to find a more efficient way</p>
  
  <p>this transform is useful because many methods f need input=c(x1,x2) instead of input = ..., if you want get result of each element of the column
  you can use sapply/lapply(height_weight,f)</p>