title: Pivot from long format to wide format in a dataframe
body: <p>I have the dataframe below:</p>
  <pre><code>dput(Moment[1:15,])
  structure(list(SectionCut = c(&quot;1&quot;, &quot;1&quot;, &quot;1&quot;, &quot;1&quot;, &quot;2&quot;, &quot;2&quot;, &quot;2&quot;, 
  &quot;2&quot;, &quot;3&quot;, &quot;3&quot;, &quot;3&quot;, &quot;3&quot;, &quot;Left&quot;, &quot;Left&quot;, &quot;Left&quot;), N_l = c(&quot;1&quot;, 
  &quot;2&quot;, &quot;3&quot;, &quot;4&quot;, &quot;1&quot;, &quot;2&quot;, &quot;3&quot;, &quot;4&quot;, &quot;1&quot;, &quot;2&quot;, &quot;3&quot;, &quot;4&quot;, &quot;1&quot;, &quot;2&quot;, 
  &quot;3&quot;), UG = c(&quot;84&quot;, &quot;84&quot;, &quot;84&quot;, &quot;84&quot;, &quot;84&quot;, &quot;84&quot;, &quot;84&quot;, &quot;84&quot;, 
  &quot;84&quot;, &quot;84&quot;, &quot;84&quot;, &quot;84&quot;, &quot;84&quot;, &quot;84&quot;, &quot;84&quot;), S = c(&quot;12&quot;, &quot;12&quot;, 
  &quot;12&quot;, &quot;12&quot;, &quot;12&quot;, &quot;12&quot;, &quot;12&quot;, &quot;12&quot;, &quot;12&quot;, &quot;12&quot;, &quot;12&quot;, &quot;12&quot;, &quot;12&quot;, 
  &quot;12&quot;, &quot;12&quot;), Sample = c(&quot;S00&quot;, &quot;S00&quot;, &quot;S00&quot;, &quot;S00&quot;, &quot;S00&quot;, &quot;S00&quot;, 
  &quot;S00&quot;, &quot;S00&quot;, &quot;S00&quot;, &quot;S00&quot;, &quot;S00&quot;, &quot;S00&quot;, &quot;S00&quot;, &quot;S00&quot;, &quot;S00&quot;
  ), DF = c(0.367164093630677, 0.540130283330855, 0.590662743113521, 
  0.497030982705986, 0.000319303760901125, 0.000504925126205843, 
  0.00051127115578891, 0.000395434233037301, 0.413218926236695, 
  0.610726262711904, 0.685000816613652, 0.59474035159783, 0.483354599644366, 
  0.645710184115934, 0.625883097885242)), row.names = c(NA, -15L
  ), class = c(&quot;tbl_df&quot;, &quot;tbl&quot;, &quot;data.frame&quot;))
  </code></pre>
  <p>I want to separate the content of the column by pivoting the <code>SectionCut</code> column. I would basically want to use the opposite of pivot_longer somehow... so at the end the values in column <code>DF</code> will be shown under 5 different columns (the values of <code>SectionCut = c(&quot;1&quot;, &quot;2&quot;, &quot;3&quot;, &quot;left&quot;, &quot;right&quot;)</code></p>