    <h2 id="leverage-and-residual-components">Leverage and residual components<a class="anchor" aria-label="anchor" href="#leverage-and-residual-components"></a></h2>



<p>For a univariate response, and when <code>m = 1</code>, Cook's distance can be re-written as a product of leverage and residual components as
 $$D_i = \left(\frac{n-p}{p} \right) \frac{h_{ii}}{(1 - h_{ii})^2 q_{ii} } \;.$$</p>
<p>Then we can define a leverage component \(L_i\) and residual component \(R_i\) as</p>
<p>$$L_i = \frac{h_{ii}