get_recoveries: Query total cumulative recovered cases with ability to...

Description Usage Arguments Value Examples

View source: R/canadacovidmetrics.R

Description

Query total cumulative recovered cases with ability to specify location and date range of returned data.

Usage

1
2
3
4
5
6
7
get_recoveries(
  loc = "prov",
  date = NULL,
  after = "2020-01-01",
  before = Sys.Date(),
  datetime_type = TRUE
)

Arguments

loc

string: Specify geographic filter and aggregation of returned data. Valid loc arguments are: 'canada', 'prov' and two-letter province codes (e.g. 'ON', 'BC', etc.)

date

string: If not None, return data from the specified date YYYY-MM-DD. Superceeds 'after' and 'before' parameters.

after

string: Return data on and after the specified date YYYY-MM-DD.

before

string: Return data on and before the specified date YYYY-MM-DD.

datetime_type

boolean: Return date column as a character (FALSE) or as a Date (TRUE).

Value

Dataframe containing content of API response.

Examples

1
2
get_recoveries(loc = "ON", before = "2021-12-31")
get_recoveries(loc = "prov", date = "2021-09-01")

UBC-MDS/canadacovidmetricsR documentation built on Feb. 6, 2022, 7 a.m.