Skip to contents

API docs: https://cmu-delphi.github.io/delphi-epidata/api/flusurv.html.

Obtain information on influenza hospitalization rates from the Center of Disease Control.

See also https://gis.cdc.gov/GRASP/Fluview/FluHospRates.html.

Usage

pub_flusurv(
  locations,
  epiweeks = "*",
  ...,
  issues = NULL,
  lag = NULL,
  fetch_args = fetch_args_list()
)

Arguments

locations

character. List of locations to fetch.

epiweeks

timeset. Epiweeks to fetch. Supports epirange() and defaults to all ("*") dates. Format as epirange(startweek, endweek), where startweek and endweek are of the form YYYYWW (string or numeric).

...

not used for values, forces later arguments to bind by name

issues

timeset. Optionally, the issue(s) of the data to fetch. See the "Data Versioning" section for details.

lag

integer. Optionally, the lag of the issues to fetch. See the "Data Versioning" section for details.

fetch_args

fetch_args. Additional arguments to pass to fetch(). See fetch_args_list() for details.

Details

The list of location argument can be found in https://github.com/cmu-delphi/delphi-epidata/blob/main/labels/flusurv_locations.txt.

Data Versioning

Several endpoints support retrieving historical versions of the data. The following parameters control this and are mutually exclusive (only one can be provided at a time).

  • as_of: (Date) Retrieve the data as it was on this date.

  • issues: timeset Retrieve data from a specific issue date or range of dates.

  • lag: (integer) Retrieve data with a specific lag from its issue date.

If none of these is specified, the most recent version of the data is returned.

See vignette("versioned-data") for details and more ways to specify versioned data.

Examples

if (FALSE) { # \dontrun{
pub_flusurv(locations = "ca", epiweeks = epirange(201701, 201801))
} # }