Extract a minimum date to use in the project, based on the settings

extract_min_date(
  settings,
  temporal_extent = "extent_time",
  max_year = as.numeric(format(Sys.Date() - 365, "%Y"))
)

Arguments

settings

list. usually from yaml::read_yaml("settings/setup.yaml")

temporal_extent

Character. Name of the temporal extent within settings

max_year

Numeric. Year. e.g. 2024. Default is the last full year via as.numeric(format(Sys.Date() - 365, "%Y"))

Value

Character in date format. e.g. 1970-01-01