epiforecasts / NCoVUtils

Utility functions for the 2019-NCoV outbreak
https://epiforecasts.io/NCoVUtils/
Other
27 stars 13 forks source link

function and tests get_belgium_regional_cases #52

Closed hamishgibbs closed 4 years ago

hamishgibbs commented 4 years ago

Added a function to extract case counts and other data from Belgian Institute for Health https://epistat.wiv-isp.be/covid/.

Datasets returned:

  1. confirmed cases by date, age, sex and province: "cases_provincial".
  2. confirmed cases by date and municipality: "cases_municipal".
  3. hospitalisations by date and provinces: "hospitalisation_provincial".
  4. mortality by date, age, sex, and province: "mortality_provincial".
  5. total number of tests performed by date: "testing_national".

Also added a test for the new function. Each dataset comes from a different url so I added a test for each dataset. If this is too much it can be pared down.

hamishgibbs commented 4 years ago

Epistat – Covid19 Monitoring. Data. Sciensano, the Belgian Institute for Health. 2020. https://epistat.wiv-isp.be/covid/.

hamishgibbs commented 4 years ago

Would it be useful to return all dataframes in a list?

hamishgibbs commented 4 years ago

The datatypes are quite different so I don't think they can be combined into a single dataframe. On the website you can download all datasets as a .xlsx file with multiple worksheets

hamishgibbs commented 4 years ago

Now dataset = "all" will return a named list of all datasets.