Skip to content

Commit

Permalink
outbreaks(mpox-2024): add number of countries
Browse files Browse the repository at this point in the history
  • Loading branch information
abhidg committed Aug 29, 2024
1 parent 13d9cba commit b2b32f1
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 1 deletion.
15 changes: 14 additions & 1 deletion src/obr/outbreaks/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@

from ..plots import (
get_counts,
get_countries_with_status,
get_countries_with_anyof_statuses,
plot_epicurve,
plot_timeseries_location_status,
plot_age_gender,
Expand Down Expand Up @@ -50,14 +52,25 @@
]

outbreak_mpox_2024 = [
("data", get_counts, dict(date_col="Date_entry")),
("data", get_counts, {"date_col": "Date_entry"}),
(
"data",
get_countries_with_status,
{"country_col": "Location_Admin0", "statuses": ["confirmed", "suspected"]},
),
(
"data",
get_countries_with_anyof_statuses,
{"country_col": "Location_Admin0", "statuses": ["confirmed", "suspected"]},
),
(
"figure/epicurve_source_report",
plot_epicurve,
{
"title": "Date of report in primary source",
"date_col": "Source_I_Date report",
"groupby_col": "Case_status",
"values": ["confirmed", "suspected"],
},
),
(
Expand Down
5 changes: 5 additions & 0 deletions src/obr/outbreaks/mpox-2024.html
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,9 @@ <h2>Summary</h2>
suspected cases as of {{ date }}
</p>

<p>The Mpox 2024 outbreak has been detected in {{ n_countries_confirmed_or_suspected }} countries, with
either confirmed or suspected cases</p>.

<figure>

{{{ epicurve_source_report }}}
Expand Down Expand Up @@ -81,6 +84,8 @@ <h2>Summary</h2>
used in this report are available from our data repository Should you identify any issues or have questions please
raise an issue on <a href="https://github.com/globaldothealth/outbreak-data">GitHub</a> or write to
us: <a href="mailto:[email protected]">[email protected]</a>.</p>
If you cite this report, please also cite the relevant sources, which are
mentioned in our <a href="https://github.com/globaldothealth/outbreak-data/wiki/GHL2024.D11.1E71">outbreak information page</a>.

</main>
</body>
Expand Down
9 changes: 9 additions & 0 deletions tests/test_status_data.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
ID,Country,Case_status
1,Antarctica,confirmed
2,Antarctica,suspected
3,Atlantis,confirmed
4,Atlantis,confirmed
5,Atlantis,confirmed
6,Midgard,suspected
7,Midgard,suspected
8,Isengard,probable

0 comments on commit b2b32f1

Please sign in to comment.