Aggregate County Maps

In counties with high populations, individual zip codes are often cluttered closely together and are very hard to depict legibly on a county map. Alternatively, rural counties may have only one or two zip codes for the entire county. Because of this difference, OptiMap™ depicts counties with a large number of zip codes differently than counties with a small number of zip codes.

In most cases, counties are composed of a number of map shapes, which represent individual zip codes. In this case, the map shape's nameclass field is set to Non Unique Zip.

However, when a county has a large number of zip codes, the county is composed of map shapes that represent 3-digit zip code regions. Such counties are known as aggregate county maps.

For example, in the map of Los Angeles county, instead of having a separate shape for each zip codes 90210, 90211, and so on, there is a single map shape for all zip codes that begin 902. This map shape is named 902xx. By doing this, the map of L.A. county becomes much more readable.

Note the following behavioral differences for aggregated shapes:

For more information about building a map system that incorporates zip codes, see Building a Map Drilldown System with Zip Codes in the Corda® 7 Developer Reference.

Setting Data for Aggregated Shapes

There are two different strategies for setting the data of an aggregated map shape. First, you can target the map shape directly by name. This works exactly as you expect it to work. For example, the following example targets the data item via PCScript, assuming a map layer name of DataLayer:

48201.setValues(DataLayer;770xx,80;775xx,90)

However, if you target the data this way, you must manually sum all of the data in the zip code group. This typically means you have to build two different data retrieval methods—one for counties with regular zip codes and one for counties with aggregated zip code groups.

Alternatively, set the data in an aggregated map shape by targeting the individual zip codes belonging to its zip code group. OptiMap automatically sums all individual zip codes in a zip code group and sets the value of the aggregated shape to the resulting sum.

For example, the following PCScript is equivalent to the previous line of PCScript in its results:

48201.setValues(DataLayer;77001,40;77005,19;77053,21;77512,12;77590,70;77599,8)

In most cases, this allows you to use the same data retrieval and parsing strategy for both regular and aggregate county maps.

Note: These strategies also apply to data imported from files, URLs, ITXML, or setMapDBQuery statements.