Skip to contents

Iterates over the datasets defined in nyc_datasets, downloads each one via process_dataset(), combines them into a single sf object, fixes invalid geometries, and writes the results to a timestamped output directory.

Usage

download_all_boundaries(
  output_dir = "outputs",
  auto_detect_latest = TRUE,
  preferred_cycle = NULL,
  external_data_dir = "data/external",
  datasets = NULL
)

Arguments

output_dir

Base directory for timestamped run outputs. Default "outputs".

auto_detect_latest

Logical. Attempt to auto-detect the latest DCP cycle letter. Default TRUE.

preferred_cycle

Optional single letter to pin a DCP cycle.

external_data_dir

Path to local fallback files. Default "data/external".

datasets

A tibble of dataset definitions. Defaults to nyc_datasets.

Value

The path to the timestamped run directory (invisibly).