title: Unnest a list column directly into several columns
body: <p>Can I unnest a list column directly into <em>n</em> columns?</p>
  
  <p>The list can be assumed to regular, with all elements being of equal length.</p>
  
  <p>If instead of a list column I would have a character vector, I could <code>tidyr::separate</code>. I can <code>tidyr::unnest</code>, but we need another helper variable to be able to <code>tidyr::spread</code>. Am I missing an obvious method?</p>
  
  <p>Example data:</p>
  
  <pre><code>library(tibble)
  
  df1 &lt;- data_frame(
    gr = c('a', 'b', 'c'),
    values = list(1:2, 3:4, 5:6)
  )
  </code></pre>
  
  <blockquote>
  <pre><code># A tibble: 3 x 2
    gr    values   
    &lt;chr&gt; &lt;list&gt;   
  1 a     &lt;int [2]&gt;
  2 b     &lt;int [2]&gt;
  3 c     &lt;int [2]&gt;
  </code></pre>
  </blockquote>
  
  <p>Goal:</p>
  
  <pre><code>df2 &lt;- data_frame(
    gr = c('a', 'b', 'c'),
    V1 = c(1, 3, 5),
    V2 = c(2, 4, 6)
  )
  </code></pre>
  
  <blockquote>
  <pre><code># A tibble: 3 x 3
    gr       V1    V2
    &lt;chr&gt; &lt;dbl&gt; &lt;dbl&gt;
  1 a        1.    2.
  2 b        3.    4.
  3 c        5.    6.
  </code></pre>
  </blockquote>
  
  <p>Current method:</p>
  
  <pre><code>unnest(df1) %&gt;% 
    group_by(gr) %&gt;% 
    mutate(r = paste0('V', row_number())) %&gt;% 
    spread(r, values)
  </code></pre>