Skip to contents

This function generates and writes ensemble-only forecast data.

Usage

write_ref_date_summary_ens(
  reference_date,
  base_hub_path,
  hub_reports_path,
  disease,
  horizons_to_include = c(0, 1, 2),
  population_data,
  excluded_locations = character(0),
  output_format = "csv",
  targets = NULL
)

Arguments

reference_date

character, the reference date for the forecast in YYYY-MM-DD format (ISO-8601).

base_hub_path

character, path to the forecast hub directory.

hub_reports_path

character, path to forecast hub reports directory.

disease

character, disease name ("covid" or "rsv").

horizons_to_include

integer vector, horizons to include in the output. Default: c(0, 1, 2).

population_data

data frame with columns "location" and "population".

excluded_locations

character vector of location codes to exclude from the output. Default: character(0).

output_format

character, output file format. One of "csv", "tsv", or "parquet". Default: "csv".

targets

character vector, target name(s) to filter forecasts. If NULL (default), does not filter by target.

Value

invisibly returns the file path where data was written