Treemap
A Treemap Chart is a visualization that represents hierarchical data as a set of nested rectangles. Each branch of the hierarchy is represented as a larger rectangle, while its sub-branches are nested inside. The size of each rectangle corresponds to a quantitative value, and colors can be used to encode categories or additional metrics.
Treemaps allow users to see proportions, compare categories, and drill into hierarchies in a compact visualization.
Best Situations to Use
Use a Treemap when you want to:
Show part-to-whole relationships in hierarchical data.
Compare the relative size of categories and subcategories.
Visualize resource allocations, market share, or population distributions.
Explore large datasets where space efficiency and hierarchical drill-down are important.
Example: A treemap can display the global population distribution, with countries as parent rectangles and states/cities nested inside.
Properties of the Treemap Chart
Tooltip
Customize the informational pop-ups displayed when hovering over treemap rectangles:
Show Tooltip: Toggle tooltip visibility.
Configuration:
Background Color
Opacity
Border Color
Tooltip Font Size
Box Width
Precision (decimal values)
Component Formatter: Apply consistent formatting across components.
Custom Tooltip: Supported via the Tooltip (Default & Custom) configuration.
Title
Title Box Color: Background color of the title container.
Show Title Box / Show Title: Toggle visibility of title box and text.
Title Bar Height: Adjust height.
Description: Add descriptive text.
Font Properties: Customize color, size, style, weight, family, alignment, and decoration.
Dataset Description: Populate title dynamically from mapped dataset.
Subtitle
Show Subtitle: Toggle subtitle visibility.
Description: Add supporting subtitle text.
Font Properties: Customize subtitle color, size, style, weight, family, alignment, and decoration.
Formatter
Unit: Define measurement units.
Precision: Number of decimals.
Currency: Format numbers with a currency symbol.
Position: Place unit/currency before or after numbers.
Number Formatter: Select International or Indian number format.
Export Options
Context Menu: Enable right-click export in preview mode.
Supported Formats: Excel (.xlsx), CSV (.csv), JPEG (.jpg), PNG (.png), PPTX (.pptx), PDF (.pdf).
Print Option: Direct print functionality.
Export Metadata: Add heading, subheading, and filename.
Global Export Type: Define default export format (Screenshot or Tabular).
Chart Variants
Treemaps can be styled by modifying appearance properties, including colors, hierarchy, and label configurations, to provide different perspectives of hierarchical data.
Dataset Mapping
To configure a Treemap chart:
Value Field: e.g., Population (numeric measure).
Hierarchy:
Parent: e.g., Country.
Child: e.g., State → City.
This setup allows a treemap where each country is a rectangle, subdivided by states and cities, sized according to population.
Example
Using the sample dataset:
Value: Population
Parent Hierarchy: Country
Child Hierarchy: State → City
The Treemap displays relative population sizes across countries, states, and cities, making it easy to identify the largest regions at a glance.