census_geocoder_batch: Function to geocode a batch (data frame) of addresses in...

View source: R/resource-census-geocoder.R

census_geocoder_batchR Documentation

Function to geocode a batch (data frame) of addresses in street/city/state/zip format

Description

Function to geocode a batch (data frame) of addresses in street/city/state/zip format

Usage

census_geocoder_batch(
  batch,
  street = street,
  city = city,
  state = state,
  zip = zip,
  endpoint = census_geocoder_api_endpoint(),
  returntype = "locations",
  benchmark = purrr::flatten(purrr::keep(census_geocoder_api_benchmarks(),
    ~.x$isDefault)),
  vintage = purrr::flatten(purrr::keep(census_geocoder_api_vintage()$vintages,
    ~.x$isDefault)),
  cache_dir = workflow::build_dir("census-geocoder-cache")
)

Arguments

batch

data frame containing columns with parts of the address

street

bare symbol for street column

city

bare symbol for city column

state

bare symbol for state column

zip

bare symbol for zip code column

cache_file

optional path to file to use to cache results to avoid submitting them multiple times. Can be shared between calls or it will be based on a hash of the batch input data.

Value

list of geocoded components and resulting tables with some simplified output


sakrejda/workflow documentation built on Nov. 18, 2024, 3:02 a.m.