GBAT.zip_code: Geocode NYC addresses with zip code

Description Usage Arguments Details Value Examples

Description

The GBAT.zip_code function geocodes a data frame of NYC addresses using house number, street name, and zip code.

Usage

1
GBAT.zip_code(input_df, id_colname, address_colname, zip_code_colname)

Arguments

input_df

a data frame containing NYC address

id_colname

the column name of an arbitrary unique identifier

address_colname

the column name of addresses where addresses are in the format of house number and street name (e.g., 123 Smith Street)

zip_code_colname

the column name of the zip code

Details

The New York Department of City Planning's Geosupport Desktop geocoding software must be installed prior to installing the rGBAT16AB package.

Value

The GBAT.zip_code function returns almost 200 columns which are described in the Geosupport Desktop User Guide

Examples

1
2
3
4
5
6
7
8
9
# create a data frame of addresses
ADDR <- c("448 Lafayette Ave","727 Manhattan Ave","31-00 47th Ave","308 E 78th S","10 Morton St")
ZIP_CODE <- c("11205","11222","11101","10075","10014")
BORO_CODE <- c(3,3,4,1,1)
u_id <- 1:length(ADDR)
df = data.frame(u_id, ADDR, ZIP_CODE, BORO_CODE)

#geocode data frame
df_gc <- GBAT.zip_code(df,'u_id','ADDR','ZIP_CODE')

gmculp/rGBAT16AB documentation built on May 17, 2019, 7:24 a.m.