diff --git a/caimira/src/caimira/calculator/report/virus_report_data.py b/caimira/src/caimira/calculator/report/virus_report_data.py
index 6b7633d8..84f313e2 100644
--- a/caimira/src/caimira/calculator/report/virus_report_data.py
+++ b/caimira/src/caimira/calculator/report/virus_report_data.py
@@ -176,7 +176,7 @@ def calculate_report_data(form: VirusFormData, executor_factory: typing.Callable
# Probabilistic exposure
if form.exposure_option == "p_probabilistic_exposure" and form.occupancy_format == "static":
prob_probabilistic_exposure = np.array(model.total_probability_rule()).mean()
- else: prob_probabilistic_exposure = -1
+ else: prob_probabilistic_exposure = None
exposed_presence_intervals = [list(interval) for interval in model.exposed.presence_interval().boundaries()]
diff --git a/cern_caimira/src/cern_caimira/apps/templates/base/calculator.report.html.j2 b/cern_caimira/src/cern_caimira/apps/templates/base/calculator.report.html.j2
index 0868683e..88bdf0b2 100644
--- a/cern_caimira/src/cern_caimira/apps/templates/base/calculator.report.html.j2
+++ b/cern_caimira/src/cern_caimira/apps/templates/base/calculator.report.html.j2
@@ -145,19 +145,23 @@
{% if form.exposure_option == "p_probabilistic_exposure" %}
- The above {{ "result assumes" if form.short_range_option == "short_range_no" else "results assume" }} that
{{ form.infected_people }}
- {{ "occupant is infected" if form.infected_people == 1 else "occupants are infected" }}
- in the room.
- By taking into account the estimate of cases currently circulating in
{{ form.location_name }},
- the probability of on-site transmission, having at least 1 new infection in an
event
- with {{ form.total_people }} occupants, is
- {% if form.short_range_option == 'short_range_yes' %}:
-
- - {{ long_range_prob_probabilistic_exposure | non_zero_percentage }}, assuming all occupants are exposed equally (i.e. without short-range interactions).
- - {{ prob_probabilistic_exposure | non_zero_percentage }}, assuming short-range interactions occur with the infector(s).
-
+ {% if form.occupancy_format == "static" %}
+ The above {{ "result assumes" if form.short_range_option == "short_range_no" else "results assume" }} that
{{ form.infected_people }}
+ {{ "occupant is infected" if form.infected_people == 1 else "occupants are infected" }}
+ in the room.
+ By taking into account the estimate of cases currently circulating in
{{ form.location_name }},
+ the probability of on-site transmission, having at least 1 new infection in an
event
+ with {{ form.total_people }} occupants, is
+ {% if form.short_range_option == 'short_range_yes' %}:
+
+ - {{ long_range_prob_probabilistic_exposure | non_zero_percentage }}, assuming all occupants are exposed equally (i.e. without short-range interactions).
+ - {{ prob_probabilistic_exposure | non_zero_percentage }}, assuming short-range interactions occur with the infector(s).
+
+ {% else %}
+
{{ prob_probabilistic_exposure | non_zero_percentage }}.
+ {% endif %}
{% else %}
-
{{ prob_probabilistic_exposure | non_zero_percentage }}.
+
Warning: Since dynamic occupancy was defined, the results for probabilistic exposure with incidence rates have not been computed.
{% endif %}
{% endif %}
diff --git a/cern_caimira/tests/test_report_generator.py b/cern_caimira/tests/test_report_generator.py
index df49442e..a6a5a031 100644
--- a/cern_caimira/tests/test_report_generator.py
+++ b/cern_caimira/tests/test_report_generator.py
@@ -181,5 +181,5 @@ def test_static_vs_dynamic_occupancy_from_form(baseline_form_data, data_registry
np.testing.assert_almost_equal(static_occupancy_report_data['prob_inf'], dynamic_occupancy_report_data['prob_inf'], 1)
np.testing.assert_almost_equal(static_occupancy_report_data['expected_new_cases'], dynamic_occupancy_report_data['expected_new_cases'], 1)
- assert dynamic_occupancy_report_data['prob_probabilistic_exposure'] == -1
+ assert dynamic_occupancy_report_data['prob_probabilistic_exposure'] == None
\ No newline at end of file