e r"><code><span><span class="fu">long2sparse</span><span class="op">(</span><span class="va">x</span>, grids <span class="op">=</span> <span class="st">"grids"</span>, species <span class="op">=</span> <span class="st">"species"</span><span class="op">)</span></span>
<span></span>
<span><span class="fu">sparse2long</span><span class="op">(</span><span class="va">x</span><span class="op">)</span></span>
<span></span>
<span><span class="fu">dense2sparse</span><span class="op">(</span><span class="va">x</span