powered by
Fetches overture data from AWS. If a bounding box is provided, it applies spatial filtering to only include records within that area. The core code is copied from duckdbfs, which deserves all credit for the implementation
duckdbfs
open_curtain( type, spatial_filter = NULL, theme = get_theme_from_type(type), conn = NULL, as_sf = FALSE, mode = "view", tablename = NULL, read_opts = list(), base_url = "s3://overturemaps-us-west-2/release/2025-03-19.0", bbox = NULL )
An dbplyr lazy dataframe, or an sf dataframe if as_sf is TRUE
A string specifying the type of overture dataset to read. Setting to "*" or NULL will read all types for a given theme.
NULL
An object to spatially filter the result.
Inferred from type by default. Must be set if type is "*" or NULL
A connection to a duckdb database.
If TRUE, return an sf dataframe
Either "view" (default) or "table". If "table", will download the dataset into memory.
The name of the table to create in the database.
A named list of key-value pairs passed to DuckDB's read_parquet
Allows user to download data from a different mirror, such as a local directory, or a alternative release.
alias for spatial_filter. may be deprecated in the future.
spatial_filter
if (FALSE) { # interactive() bbox <- c(xmin = -120.5, ymin = 35.5, xmax = -120.0, ymax = 36.0) open_curtain("building", bbox) }
Run the code above in your browser using DataLab