ass="ot">&lt;-</span> tidyr<span class="sc">::</span><span class="fu">pivot_wider</span>(</span>
<span id="cb25-3"><a href="get-started.html#cb25-3" tabindex="-1"></a>  <span class="at">data =</span> data_long,        <span class="do">## the long data set</span></span>
<span id="cb25-4"><a href="get-started.html#cb25-4" tabindex="-1"></a>  <span class="at">names_from =</span> metric,     <span class="do">## new column names</span></span>
<span id="cb25-5"><a href="get-started.html#cb25-5" tabindex="-1"></a>