How to create DotDensity theme in MapXtreme

UPDATED: September 10, 2018

A Dot Density theme is a Feature Style modifier that draws the fill pattern of a Region using dots based on the numeric value of the theme's expression. 

Dot Density themes use dots to represent the data value associated with a boundary or region. The total number of dots in a region represents that region's data value. For example, if you have 10,000 senior citizens in a county, and each dot represents 100 senior citizens, there would be 100 dots in the county boundary.

A dot density theme is useful for showing raw data where one dot represents a large number of something: population, number of fast food restaurants, number of distributors who carry a brand of soda, etc.

The following code will create an example of a Dot Density Theme:
public static void MapInfo_Mapping_Thematics_DotDensityTheme(Map map) 
  // Load a map based on one table
  map.Load(new MapTableLoader(""));  

  // Create a dot density theme.
  // Add it as a modifier.
  FeatureLayer lyr = map.Layers["Mexico"] as FeatureLayer;
  DotDensityTheme thm = new DotDensityTheme(lyr, "Pop_90", 
    "Mexico Pop", System.Drawing.Color.Red, DotDensitySize.Large);

  // thm.DotColor is System.Drawing.Color.Red
  // thm.DotSize is DotDensitySize.Large

  // Set each dot to represent 20,000 people
  thm.ValuePerDot = 20000;



Environment Details

Products affected: MapXtreme .NET
Product Feature: Thematics



  • No Downloads