title: How to assign multiple columns to data.frame without repeating function call
body: <p>Why doesn't this work for an example? There's same value in each row and warning as well</p>
  
  <pre><code>data &lt;- data.frame(id = 1:10)
  slowCall &lt;- function(id) data.frame(b = rep(id, 3), c = runif(3))
  data[,c("d", "e")] &lt;- sapply(data$id, function(id) {
   tmp &lt;- slowCall(id)
   list(sum(tmp$b), min(tmp$c))
  })
  
  Warning message:
  In `[&lt;-.data.frame`(`*tmp*`, , c("d", "e"), value = list(3L, 0.104784948984161,  :
   provided 20 variables to replace 2 variables
  print(data)
     id d         e
  1   1 3 0.1047849
  2   2 3 0.1047849
  3   3 3 0.1047849
  4   4 3 0.1047849
  5   5 3 0.1047849
  6   6 3 0.1047849
  7   7 3 0.1047849
  8   8 3 0.1047849
  9   9 3 0.1047849
  10 10 3 0.1047849
  </code></pre>