How to add add lat/long to your data for more precise #Tableau mapping

Introduction

I work with a lot of site-specific data that typically does not have latitude and longitude information included. I am generally given an address, city, state and zip for the data location.  Although Tableau will automatically map this data  at the state, city, and zip levels using generated latitude and longitude, many times I need to be more precise in making maps because I have more than one sample per zip code, for example.

A Simple Method For Adding Lat/Long to Your Data

There is a simple and cost-free way to quickly add lat/long to your database. This blog post describes one method that I use. There are probably other methods available, but this method has worked for me many times over the past few years and doesn’t require much technical expertise to complete the task successfully.

Step 1

You have a database that contains an address, city, state and zip as shown in Figure 1.

Addresses_Initial

Figure 1 – An example of a database without lat/long.

 

Your goal is to get the latitude and longitude added to the database as shown in Figure 2.

Addresses

Figure 2 – Your goal is to get Lat/Long added to the database.

 

Step 2

Copy the addresses and place them in a web page that does batch geocoding as shown in Figure 3.

Geocoding

Figure 3 – Perform batch geocoding on your data.

 

The highlighted block shown in Figure 3 contains the lat/longs that you will paste back into your database.

Step 3

Read the data into Tableau to be able to map your locations down to the site-specific level, (i.e. at a specific lat/long) as shown in Figure 4.

Tableau_Map_Actual

Figure 4 – Sites displayed in Tableau at the lat/long locations retuned from the batch geocoding process.

 

Step 4

If you want more details about this method, watch the video below. I go into quite a bit of detail on how this method is completed.

One thought on “How to add add lat/long to your data for more precise #Tableau mapping

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s