Module:Medical cases data/doc
Appearance
This module inserts charts and maps of medical cases related to a pandemic, broken down by subregions.
caseTable
[edit]Inserts a table of cases and deaths by region.
Usage: {{#invoke:Medical cases data|caseTable|config=Configuration}}
{{#invoke:Medical cases data|caseTable
|config=San Francisco Bay Area
}}
Counties | Cases[a] | Recov.[b] | Deaths | Pop. (2019) | C/1M | Ref. |
---|---|---|---|---|---|---|
9 | 1,936,915 | 11,212 | 7,739,378 | 250,268 | ||
Santa Clara | 527,431 | ? | 3,219 | 1,927,852 | 273,585 | d c[1] |
Alameda[c] | 400,532 | ? | 2,483 | 1,671,329 | 239,649 | d c[2] |
Contra Costa | 302,824 | 300,666 | 1,601 | 1,153,526 | 262,520 | d c[3] |
San Francisco | 203,788 | ? | 1,373 | 881,549 | 231,170 | d c[4] |
San Mateo | 184,001 | ? | 946 | 766,573 | 240,031 | d c[5] |
Sonoma | 119,749 | 118,903 | 668 | 494,336 | 242,242 | d c[6] |
Solano | 118,904 | 118,073 | 441 | 447,643 | 265,622 | d c[7] |
Marin | 44,650 | 7,030 | 274 | 258,826 | 172,510 | d c[8] |
Napa | 35,036 | 27,672 | 207 | 137,744 | 254,356 | d c[9] |
|
map
[edit]Inserts an interactive map of cases and deaths by region.
Usage: {{#invoke:Medical cases data|map|config=Configuration|frameWidth=Frame width in pixels|frameHeight=Frame height in pixels|caption=Caption as wikitext}}
{{#invoke:Medical cases data|map
|config=San Francisco Bay Area
|frameHeight=300
}}
Configuration
[edit]Run this Wikidata Query Service query to obtain a list of localized outbreaks to add to the regions
property in the table.
return {
caption = "Cases by county", -- Table or map caption as wikitext
outbreakItem = "Q94050008", -- QID of the Wikidata item representing the
regionTerm = "Counties", -- Term for each region, used as the first column's header
regionNamePattern = "(.+) County", -- Naming pattern for regions, applied to each region's item's label to display a short name in first column; see [[mw:Extension:Scribunto/Lua reference manual#Patterns]]
populationDate = "2020-01-01", -- Date of the population figures used to calculate per-capita infection rates
regions = {
-- Add a table for each region's outbreak
{
-- QID of the outbreak
entity = "Q94259368",
-- If there is tabular data for the outbreak, specify any column names that differ from the defaults
columns = {cases = "AC_CumulCases", deaths = "AC_CumulDeaths"},
-- Optional footnote for the region as wikitext
note = "Including cases in the City of Berkeley, which are reported by the Berkeley Public Health Division.",
},
},
columnNotes = {
cases = "Cumulative cases reported by each county's health department.", -- (Optional) Footnote for the "Cases" column as wikitext
recoveries = "Counties differ in what they consider to be a recovery.", -- (Optional) Footnote for the "Recoveries" column as wikitext
deaths = "Includes suspected cases.", -- (Optional) Footnote for the "Deaths" column as wikitext
}
}
Available configurations
[edit]
- ^ “Respiratory virus data”, “COVID cases and deaths dashboard”, “COVID-19 hospitalizations by date”, “COVID-19 Hospitalizations Dashboard”, “Count of deaths with COVID-19 by date”, “Deaths with COVID-19 by age group”, Santa Clara County Public Health. November 15, 2024.
- ^ Alameda County Data Sharing Initiative, Alameda County Public Health Department. November 16, 2024.
- ^ Contra Costa Health Services. May 22, 2023.
- ^ “ARCHIVED: COVID-19 Cases by Geography Over Time”, “COVID-19 Deaths Over Time”, “COVID-19 Hospitalizations”, DataSF, San Francisco Department of Public Health. November 12, 2024.
- ^ San Mateo County Health. April 27, 2023.
- ^ Case and Testing Data, Hospitalizations and Deaths, County of Sonoma. November 21, 2024.
- ^ Solano County Public Health. March 2, 2023.
- ^ “COVID-19 Case Disposition”, “COVID-19 Cumulative Demographics”, “Total Cases and Recovered by Date Reported among Marin County Community Residents”, “Total Hospitalizations and Deaths by Event Date among Marin County Community Residents”, Marin Health & Human Services. February 14, 2023.
- ^ “COVID-19 in Napa County”, “Landing Page”, “Situation Update Archive”, Napa County Health & Human Services Agency. May 14, 2023.