You are here: Home > Maps > Los Angeles Ethnicity > Creating four-color layer symbology
Los Angeles Ethnicity: Using the "four-color" theorem in layer symbology
Rate this effect!
The city polygons are symbolized such that no city has the same color as any adjacent city.
The city polygons were symbolized so that no city has the same tint as any adjacent city.

What: Applying the "four-color" theorem in mapping means that polygon data are symbolized so that no adjacent polygons have the same color. This is a common technique used in mapping -- it helps the reader to clearly distinguish unique features. You may have seen this approach used in atlas mapping to help distinguish the various states or countries. There has been extensive work done on this in the fields of mathematics (on proofs of the theorem) and computer science (on the efficiency of solving the problem). Work has also been done on the application of this in cartography -- a sample script helped us apply it on this map.

Why: The reason to use the four-color theorem in mapping is to minimize the number of colors necessary to show unique features. Cartographically, fewer colors usually means on the map to distract the map reader. We used it on this map to help readers distinguish the city limits, but we carefully chose the symbology so that this layer remained visually in the background of this map.

How: To use the four-color theorem on our map, we used a script that you can download -called Map Coloring - Four Color a Map from ArcScripts. Install it as directed in the readme file. You will be instructed to register the DLLs. Here's how to do that using Regsvr32:

  1. From the Taskbar click Start then Run.
  2. Type: regsvr32 <the full path for the DLL file>. For example:
  3. regsvr32 c:\Progra~1\ArcGIS\ArcToo~1\Toolboxes\BnchMrkTopo4Color.dll

  4. Click OK.

Once the tool was installed, we followed these steps:

  1. Add the Four-Color a Map toolbox to your map.
  2. Add a new long integer field to your polygon data -- this field will be one of the inputs to the Four-Color a Map tool.
  3. Run the Four-Color a Map tool, specifying your polygon data and the field you added as parameters.
  4. Open the Layer Properties for your polygon layer, and click on the Symbology tab.
  5. Change the symbology to use Unique Values and set the Value field to be the field you added.

We decided to use a set of light gray tints that matched our background color. This combination helped the layer to remain in the background of the map while still allowing map readers to see where different cities were located.

tbx not working in 10.0 posted by Cory Eicher on May 16 2011 6:51AM

Has anyone had any success running the geoprocessing toolbox version of this in 10.0?

I tried this on a file .gdb (created in 10.0) and it's not working for me. It's working with the same data in 9.3.1. I only get generic GP errors.


Probably 9.2 posted by Aileen Buckley on May 16 2011 9:02AM
This set of tools was developed for an older version of ArcGIS -- probably 9.2. We have not updated it for 10. As it is a developer's sample, it is not under our regular support and upgrade. If we have a chance to work on this, we will. In the meantime, if others work on it to get it up to snuff for 10, you can let us know and we can post your updates here, too.

If you would like to post a comment, please login.

Contact Us | Legal | Privacy |