ss="co"># market prices</span></code></pre></div>
<div class="section level3">
<h3 id="gains-losses-calculation">Gains &amp; Losses Calculation<a class="anchor" aria-label="anchor" href="#gains-losses-calculation"></a>
</h3>
<p>Based solely on this two data frames it is possible to compute the so-called realized gains (RG), realized losses (RL), paper gains (PG), and paper losses (PL), as defined by L. Mazzucchelli et al. (2021).</p>
<p>To sum up the main concepts are the followings:</p>
<ul>
<li><p>Realiz