This is part of my continuous experiment to better visualize spatial data. An earlier of post is here:
It was a revelation to me when I saw the California population distribution like above. Half of the Californians are squeezed in between Los Angeles and San Diego.

When I was working on visualizing the disease cases and ratios in California, I wanted to see the spatial distribution of the disease cases. And I used Pareto method to help create contiguous quantiles (equal portions in population) on the map, from which resulted the above picture. More examples are as follows. We can use the Pareto measure to create various partitions as we wish.
This is a quasi-quartile partition of the populations based on county data. We see that Los Angeles county got about one quarter of the total population. No wonder it is the most populous county in the state.
This picture shows that the north of San Francisco Bay Area is quite sparse with only 5% of the population. About a quarter of the population live between San Francisco and Los Angeles. So, we got good insights into the population distribution in California.

The Visual Pareto Approach

It is custom to analyze data distribution along the North-South or East-West axis. For example, the population density is more on the east and west coasts than in the inland. This is an East-West/longitudinal analysis approach because of the particular geography of the United States. For a coastal state like California, we may be interested in understanding the North-South/latitudinal distribution of the population.

In the above examples we use the North-South approach. The county population data in California is scraped from here. The county latitude data is generated from Tableau but has to be exported to an Excel file and re-imported into Tableau, because we couldn't directly reference the latitude(generated) in our calculation. (What a waste! Thus I created a request for the feature. Seems other people already asked for it long time ago. Please vote for them if you believe it's useful.)

Assume Pareto cumulation will be computed North-South along the latitude axis. We can create a regular Pareto chart as below.
The Pareto chart may tell us a few things. But it's not so intuitive about the population distribution. In combination with map partition, we create something that's easy to visually interpret.

The main steps to create the above partitioned maps are:

1.Create a table to get the latitude of all the data points (counties here). Export it to Excel and import it again into Tableau. Then the latitude data is made referenceable.
2.Use this data source as the primary to blend with the original data set from which we can get measures (such as populations or disease cases).

3.Put County in the Detail shelf and sort it by AVG(Latitude) descendingly from North to South.

4.Drag Population to the Detail shelf and set Sum(Population) to quick table calculation of Running Total. Set the table calculation to compute using County. In this step we may create a few more measures such as percent of total to show in tooltips.

5.Create partitions to color the map. (The calculation is based on the Pareto method.) Then, drag the Quartiles (in this example) to the Color shelf.
Voila. The workbook can be download here.

0

Add a comment

(Refresh the page if you want to view the gif image multiple times. Or go to Tableau Public and click the button at the top-right corner.)

Jake and I collaborated on a dashboard. He told me that he learnt a way to create an in-place help page in Tableau. He first saw it at a conference somewhere and couldn't recall who the speaker was. So I am blogging here about it but the credit goes to somebody else. If anyone knows who the original creator is, leave a comment below.

The key idea is to float a semi transparent worksheet on top of the dashboard, where a help text box is strategically placed on top of each chart. This way, we can explain how to view each chart and what data points are important, etc. This worksheet is collapsible by a show/hide button. 

Below I would like to show how this worksheet can be constructed.

1. Sheet with a single data mark.

  • Double click the empty space in Marks panel and add two single quotes. Make the null pill a text label. This creates a single null mark.
  • Set the view as "Entire View"

2. Create an show/hide button

  • Go to the target dashboard
  • Drag a floating vertical container to the dashboard, making it cover all the area of interest.
  • Drag the Single Null Mark sheet and drop it into the above container. Hide the sheet title.
  • Create an open/close button for the container and place the button at the top-right corner.

3. Add annotations

  • Format the sheet background opacity as 70% in the layout manager             
  • Select area annotations and place them anywhere of interest. 
  • Write help text and format it to highlight important messages.  
  • The text can serve as functional guide and/or insight guide.

Here is an example. Feel free to download the workbook and explore. Click the "i" button at the top-right corner to view the in-place help. 

0

Add a comment

Blog Archive
Loading
Dynamic Views theme. Powered by Blogger. Report Abuse.