</span><span class="sd">&quot;&quot;&quot;Calculate the median error, discounting nan values</span>

<span class="sd">    Parameters</span>
<span class="sd">    ----------</span>
<span class="sd">    predictions, targets : array_like</span>

<span class="sd">        Time series or arrays to be analyzed</span>

<span class="sd">    Returns</span>
<span class="sd">    -------</span>
<span class="sd">    med : float</span>
<span class="sd">        Median error</span>
<span class="sd">    &quot;&quot;&quot;</sp