GeoDaCenter/opioid-environment-toolkit

Minor code typo in Section 2.3: Convert to Spatial Data

Opened this issue · 3 comments

In these code chunks, the methadoneClinics data frame is both piped to geocode() and in the first argument of geocode(). Did you mean to go with just the former or just the latter?

geoCodedClinics <- methadoneClinics %>%
geocode(methadoneClinics, address = 'fullAdd',
lat = latitude, long = longitude, method = 'cascade')

geoCodedClinics <- methadoneClinics %>%
geocode(methadoneClinics, address = 'fullAdd',
lat = latitude, long = longitude, method = 'cascade')
geoCodedClinics

Or is there something I missed? https://geodacenter.github.io/opioid-environment-toolkit/geocodingAddress-tutorial.html seems to have rendered without error. I am only getting the errors when I run the code locally.

That's an error - you can just use it in the first argument of geocode(). Will update the script shortly. Thanks for the catch.