nextgen, tutorial,

Geocoding Multiple Addresses:Parks in Putrajaya-Cyberjaya

najmi najmi Follow Feb 13, 2020 · 2 mins read
Geocoding Multiple Addresses:Parks in Putrajaya-Cyberjaya
Share this

Geocoding is the process of converting addresses actual locations (like “Cyberjaya Lake Gardens Persiaran Semarak Api, Cyber 4, 63000 Cyberjaya, Selangor, Malaysia”) into geographic coordinates (like latitude 2.9361259 and longitude 101.6415532), which you can use to place markers on a map, or position the map.

A powerful geographic information system (GIS), can turn a list of addresses into spatial data for mapping or combining with other data. The ability to geocode in a country/region is dependent upon the road data coverage and the geocoding precision of the geocoding service.



There are several geocoding tools available to get the specific geocode for a particular location. They each have their own strengths and weaknesses, so I thought it would be appropriate to share what I have learned.

Step by step : Run Script using Python

import pandas as pd
df = pd.read_csv("parkputrajaya_MY4.csv")

import googlemaps
gmaps_key = googlemaps.Client(key = "[Your Google Client ID]")

df["LAT"] = None
df["LON"] = None

for i in range(0, len(df),1):
    geocode_result = gmaps_key.geocode(df.iat[i,1])
        lat = geocode_result[0]["geometry"]["location"]["lat"]
        lon = geocode_result[0]["geometry"]["location"]["lng"]
        df.iat[i, df.columns.get_loc("LAT")] = lat
        df.iat[i, df.columns.get_loc("LON")] = lon
        lat = None
        lon = None        

List of Geocoding Tools

Geo for Google Docs
Script that geocodes addresses within Google Spreadsheets, using MapQuest or Yahoo geocoding APIs.

Will geocode up to 250 addresses and plot on a Google Map. Once the map has been created scroll down for the link to download as a KML file.

ArcGIS Online
Geocodes up to 250 addresses.

GPS Visualizer

Stata: Geocode command
This utilizes the Google Maps to return latitude and longitude within the statistical package Stata.

Geocoding for a limited number of records.

Excel Geocoding Tool

Google Geocoding
Google requires you get an API key from them in order to do geocoding.

Batch geocoder for journalists
Locations to coordinates at rocket speed



Join Newsletter
Get the latest news right in your inbox. We never spam!
Written by najmi Follow
Love to explore new ideas and empowering +Emotional Intelligence for better future!