tbd_address_to_tract: Address to Tract

View source: R/tbd_address_to_tract.R

tbd_address_to_tractR Documentation

Address to Tract

Description

Provides access to the US Census Bureau batch endpoints for locations and geographies. The function has been developed specifically with large data sets in mind. only unique addresses are passed to the API for geocoding. If a data set exceeds 1,000 unique addresses, it will be automatically subset into appropriately sized API calls, geocoded, and then put back together so that a single object is returned. The function implements iteration and optional parallelization in order to geocode datasets larger than the API limit of 10,000 and more efficiently than sending 10,000 per request. The function therefore provides an efficient solution to batch geocoding via the Census Bureau’s services. This implementation assumes that your data are contained in a data.frame or tibble, and that address data are split into a number of component variables: street address, city, state, and five digit zip code. file to the census tract API. Please visit the following link for more details: Census Tract Geocoding

Usage

tbd_address_to_tract(
  .data,
  id = NULL,
  street,
  city = NULL,
  state = NULL,
  zip = NULL,
  parallel = 1
)

Arguments

.data

A dataframe

id

Unique ID

street

A column that consist of house number and street address

city

City column

state

State column

zip

Zip column

Examples

## Not run: 
tbd_address_to_tract(data = data frame,
                     id = id,
                     street = street,
                     city = city,
                     state = state,
                     zip = zip_code,
                     parallel = 1)
  
## End(Not run)

j-hagedorn/TBDfun documentation built on June 13, 2024, 5:38 a.m.