Smart Mapping: Relationship

Visualize patterns normally hidden between related numeric attributes

This quick guide introduces how to make a map that visualizes the relationship between two numeric attributes in point, line, or polygon feature data. Most maps of numeric data focus on a single attribute. Though, often we need to understand our data in relation to other attributes to explain the patterns we're seeing. For example, a map showing the relationship between a hurricane’s wind speed and its barometric pressure help better communicate where hurricanes tend to intensify (over warm water) and weaken (overland). In order to really understand our data, context and data relationships need to be considered.

What is the Relationship Style?

Relationship maps are an easy way to visualize and compare multiple attributes. These maps allow you to find where the relationship between the attributes is most or least pronounced, all within a single map. In essence, a relationship map combines two data patterns to show where they converge and where they diverge.

This drawing option is easy to try and can provide valuable insight into your data and the patterns hidden within.

For example, here is a choropleth map showing the percentage of diabetes in the US by county.

Here, we have another thematic choropleth map showing the percent of the population classified as obese:

At a glance, these patterns look similar, but where are the patterns both high, both low, or occurring strongly on their own? Relationship mapping combines these two map patterns in order to explore where they overlap or diverge. The style takes two individual color ramps to show a combination of the patterns resulting in a grid and map that looks like this:

The two schemes converge, allowing us to explore where attributes may or may not be related.

This process results in one informative, useful map negating the need to create two maps that only tell half of the story.

From this map, we see that the corners tell us a great deal of information. The purple values show where there are high rates of both obesity and diabetes. The darkest pink values show where there is a high amount of diabetic population, but fewer people with obesity. The darkest blue values show where people have a higher likelihood to be obese, but less likely to have diabetes

This map helps you quickly visually assess converging or diverging patterns. This style is particularly helpful for two attributes with a known, documented relationship or for exploring suspected relationships needing further analysis. 

Additionally, there is an option to add a third variable into your relationship map, creating a relationship and size map. As with the relationship style, this style applies distinct graduated color ramps to the classified data in two attributes and combines the color ramps to show relationships between them. Size is added to represent a third numeric attribute you specify using different-sized symbols.

Continuing with the previous example, we can add a third numeric attribute, population, to show where there are high rates of diabetes, obesity, or both, and the total population of the area.

Classically known as a bivariate choropleth map or a trivariate map (with the addition of size), these maps have  always been possible within ArcGIS , but with a  great deal of customization and forethought . With smart mapping, you can create these maps in minutes, easily making adjustments while you explore the data.

How to Make a Relationship Map

Smart mapping helps you create beautiful and informative maps, quickly. It sets the cartography of your layer based on the significant values within your data. Smart mapping lets anyone quickly discover patterns from attributes in their data and make meaningful maps from them. 

By selecting two or three numeric attributes from your data to compare, smart mapping will automatically recognize that you have selected numbers, and within your list of mapping styles, it will suggest the relationship (and size) mapping style.

Let's step through the creation of a relationship map. First, open  Map Viewer  in ArcGIS Online or ArcGIS Enterprise.

To begin, it is good practice to change the default basemap to a neutral option such as dark or light gray canvas or the human geography basemaps available in  Living Atlas .

This allows the data to be the focus of the map without the distraction of too much background noise.

Open the Styles pane on the right-hand side.

Select two attributes you want to compare. These need to be attributes that are numbers (integer, float, etc). In particular, this style works best with  normalized attributes  rather than counts - think standardized data such as percentages or rates. You can also normalize the attribute within the options settings if it is not pre-calculated.

In this example, we are going to compare adults who smoke cigarettes and adults who are excessive drinkers.

This data is part of the  2020 County Health Rankings  layer available from  ArcGIS Living Atlas .

Scroll down through the options and select the Relationship drawing style. 

Immediately, there is an interesting pattern within this data. Counties in orange have a high quantity of smokers, while counties in blue have a high amount of adults who drink excessively.

Counties in brown have a high amount of smokers and drinkers, while Utah and Idaho stand out as states in beige with few smokers or drinkers.

Next, select Style options to dive deeper into the symbology settings.

Within Style options, there are many ways to customize the symbology of the map. 

Let's explore these options.

The first option we see is to change the grid size. By default, this is set to a 3x3 grid which spreads the data values over 3 categories (low, middle, high). The corners show where the patterns are the strongest, so this helps differentiate the corners as areas that we would want attention.

You can also change to a 2x2 grid to show what is above or below average or change to a 4x4 grid to spread the values over more colors. 

There is also an option to change the  classification method . This determines the data value breakpoints where the colors change.

By default, the map uses quantile which ensures that each color has an equal number of features. While quantile is a good start for data exploration, it is always important to go beyond the default and bring your knowledge as the mapmaker into the data story.

Use the dropdown arrow next to the attributes to view the data histogram. Here, you can view the standard deviation and manually adjust the breakpoints.

Setting manual breakpoints is a useful way to add your own subject matter expertise to the map. If you know that a value or threshold is important such as a national statistic, set the breakpoint to that value because the map instantly reflects that perspective. 

After setting smart breakpoints, you can change the colors of the map by selecting one of the many color ramps.

Ramps can also be filtered based on appropriateness for light or dark backgrounds or color-blind friendly.

Here, we will select the second ramp and immediately see how the map changes.

After choosing colors, you can change the rotation of the grid within the legend. This changes the emphasis of the legend by putting your desired focus at the top.

The default is to show where both values are high (High - High), but you can change to one of the options from the Focus dropdown:

  • High values / Low Values
  • Low values / High Values
  • Low Values
  • None

Once the focus has been set, labels can also be adjusted to be more intuitive in order to help our map readers understand the map better. It's a powerful way to communicate the converging and diverging patterns.

Go into the Labels settings to make changes to the legend colors and labels.

In this case, some simple text changes help clarify what the colors in the corners of the grid are telling us:

Yellow - High Smoking, Low Drinking

Black - High Smoking, High Drinking

Blue - Low Smoking, High Drinking

White - Low Smoking, Low Drinking

By adding a size component, we can add additional context to the map using a third attribute.  

For example, you can show where the map's pattern coincides with areas of high or low population. 

Smart mapping recognizes the addition of a third variable and automatically switches the style to Relationship and Size.

If starting a new map from scratch, choose three attributes and then select the Relationship and Size drawing style from the list of recommendations.

The first two attributes you select show as the relationship, while the third attribute you choose will be shown by size. 

Choose Style options to make additional changes to the symbology.

Within the options, you can make changes to both the colors and the sizes used in the map.

As the previous relationship style options have already been set, go further into the size options to refine the map.

Adjusting the histogram breakpoints brings out the pattern within the population data. We can now see the midsize and large urban population centers more clearly, with the smallest size awarded to features with populations below the average. In addition, rounded numbers make the legend easier to understand.

There are also further options to explore that change the symbol style, size range, or theme.

You've seen how smart mapping and the relationship style can shine a light on hidden patterns within your data. Always go beyond the default settings in order to tune the map to the story you are interested in telling.

For example, here is a map that uses the relationship style to show hurricane paths from 1924 to 2014. Hurricanes are the strongest when pressure is low and wind speed is high. This is shown using the color pinkTo emphasize the strongest part of the hurricanes, the legend is rotated using the 'Focus' adjustment to place High - Low at the top of the grid. Custom labels further help explain the hurricane pattern on the map. Click to explore the map and legend below.

Hurricane Pressure and Speed

With smart mapping doing the heavy lifting by taking the guesswork out of setting your map properties, you can freely explore new patterns and stories you did not know were present in the data.

Try it out today, and when ready share your maps with the hashtag #smartmapping and #ArcGISOnline.

Additional Resources

The two schemes converge, allowing us to explore where attributes may or may not be related.