="name flex">
<span>def <span class="ident">win_rate</span></span>(<span>df, alternative='alternative', alternative_a='alternative_a', alternative_b='alternative_b', selected='selected', show_rank=True, voter='voter', **kws)</span>
</code></dt>
<dd>
<div class="desc"></div>
<details class="source">
<summary>
<span>Expand source code</span>
</summary>
<pre><code class="python">def win_rate(
    df,
    alternative=&#34;alternative&#34;,
    alternative_a=&#34;alternative_a&#34;,
    alternative_b=&#34;altern