{% extends "pages/base.html" %} {% load i18n %} {% block title %}{% trans "MTG Hypergeometric Calculator" %}{% endblock %} {% block content %}

{% trans "Magic: The Gathering Hypergeometric Calculator" %}

{% include "awg/_calculator_nav.html" with active_calculator="mtg_hypergeometric" %}
{% csrf_token %}
{% if not result and not error %}
{% blocktrans trimmed %} Estimate MTG card-seeing odds with library-size, turn-position, mulligan, and disjoint package assumptions. {% endblocktrans %}
{% if templates %}

{% trans "Or try a pre-loaded preset:" %}

    {% for t in templates %}
  • {{ t.name }} {% if t.description %}- {{ t.description }}{% endif %}
  • {% endfor %}
{% endif %} {% else %} {% if error %}

{% blocktrans %}Error: {{ error }}{% endblocktrans %}

{% elif result %} {% if warnings %}
    {% for warning in warnings %}
  • {{ warning }}
  • {% endfor %}
{% endif %}

{% trans "Calculator Results" %}

{% if cards_seen_label %}

{{ cards_seen_label }}

{% endif %} {% if result.probability_exact is not None %} {% endif %}
{% trans "Chance of at least selected target amount" %}{{ result.probability_at_least_percent|floatformat:2 }}%
{% trans "Chance of any target card" %}{{ result.probability_any_percent|floatformat:2 }}%
{% trans "Chance of no target cards" %}{{ result.probability_none_percent|floatformat:2 }}%
{% trans "Chance of exact target amount" %}{{ result.probability_exact_percent|floatformat:2 }}%

{% trans "Draws to Probability Thresholds" %}

{% for row in result.threshold_rows %} {% endfor %}
{% trans "Threshold" %} {% trans "Any target" %} {% trans "Selected minimum" %}
{{ row.label }} {% if row.any_reachable %}{{ row.any_draws }}{% else %}{% trans "Not reachable" %}{% endif %} {% if row.selected_reachable %}{{ row.selected_draws }}{% else %}{% trans "Not reachable" %}{% endif %}
{% if mulligan_rows %}

{% trans "London Mulligan Odds" %}

{% for row in mulligan_rows %} {% endfor %}
{% trans "Mulligans Taken" %} {% trans "Final Hand Size" %} {% trans "Keepable This Hand" %} {% trans "Cumulative Keep Chance" %}
{{ row.mulligans_taken }} {{ row.final_hand_size }} {{ row.keep_probability_percent|floatformat:2 }}% {{ row.cumulative_probability_percent|floatformat:2 }}%
{% endif %} {% if multivariate_result %}

{% trans "Two-Package Odds" %}

{% trans "Chance of seeing both package minimums" %}{{ multivariate_result.probability_percent|floatformat:2 }}%
{% endif %}
{% endif %} {% endif %}
{% endblock %}