Learn R Programming

climatehealth (version 1.0.0)

load_wildfire_data: Load wildfire and health data

Description

Loads a dataframe containing a daily time series of health and climate data, which may be disaggregated by region.

Usage

load_wildfire_data(
  health_path,
  ncdf_path,
  shp_path,
  join_wildfire_data = TRUE,
  date_col,
  region_col,
  shape_region_col = NULL,
  mean_temperature_col,
  health_outcome_col,
  population_col = NULL,
  rh_col = NULL,
  wind_speed_col = NULL,
  pm_2_5_col = NULL
)

Value

Dataframe containing a daily time series of climate and health data.

Arguments

health_path

Path to a CSV file containing a daily time series of data for a particular health outcome, which may be disaggregated by region. If this does not include a column with wildfire-related PM2.5, use join_wildfire_data = TRUE to join these data.

ncdf_path

Path to a NetCDF file containing a daily time series of gridded wildfire-related PM2.5 concentration data.

shp_path

Path to a shapefile .shp of the geographical boundaries for which to extract mean values of wildfire-related PM2.5

join_wildfire_data

Boolean. If TRUE, a daily time series of wildfire-related PM2.5 concentration is joined to the health data. If FALSE, the data set is loaded without any additional joins.

date_col

Character. Name of the column in the dataframe that contains the date.

region_col

Character. Name of the column in the dataframe that contains the region names.

shape_region_col

Character. Name of the column in the shapefile dataframe that contains the region names.

mean_temperature_col

Character. Name of the column in the dataframe that contains the mean temperature column.

health_outcome_col

Character. Name of the column in the dataframe that contains the health outcome count column (e.g. number of deaths, hospital admissions)

population_col

Character. Name of the column in the dataframe that contains the population data. Defaults to NULL. If omitted, a pop column is used when present.

rh_col

Character. Name of the column in the dataframe that contains daily relative humidity values.Defaults to NULL.

wind_speed_col

Character. Name of the column in the dataframe that contains the daily windspeed values.Defaults to NULL.

pm_2_5_col

Character. The name of the column containing PM2.5 values in micrograms. This is only required if health data isn't joined. Defaults to NULL.