Skip to contents

Process multiple models to analyze historical weather variables and crop yields

Usage

data_aggregation(
  climate_hist_dir = NULL,
  climate_impact_dir = NULL,
  climate_model = "gcm",
  climate_scenario = "rcp",
  historical_periods = NULL,
  co2_hist = NULL,
  co2_proj = NULL,
  output_dir = file.path(getwd(), "output")
)

Arguments

climate_hist_dir

Default = NULL. String for path to the processed historical climate data folder

climate_impact_dir

Default = NULL. String for path to the processed future climate data folder using weighted_climate function

climate_model

Default = NULL. String for climate model (e.g., 'CanESM5')

climate_scenario

Default = NULL. String for climate scenario (e.g., 'ssp245')

historical_periods

Default = NULL. Vector for years to subset from the historical climate data. If NULL, use the default climate data period

co2_hist

Default = NULL. Data table for historical CO2 concentration in columns [year, co2_conc]. If NULL, use built-in CO2 emission data

co2_proj

Default = NULL. Data table for projected CO2 concentration in columns [year, co2_conc]. If NULL, use built-in CO2 emission data

output_dir

Default = file.path(getwd(), 'output'). String for output directory

Value

A list of historical and projected weather variables and crop data.