Perspective - Heatmap

Component Palette Icon:
The Heatmap component visualizes magnitude across two categorical or temporal dimensions simultaneously. Each cell in the grid represents the intersection of an x and y category, colored by value. Common use cases include overall equipment effectiveness by hour and day-of-week, alarm frequency by equipment and shift, process variable intensity maps, production quality matrices, and more.
The Heatmap component has two pre-configured variants:
- Grid: The magnitude across two categorical dimensions, communicated by a stepped scale of colors with clear boundaries. This chart can be configured into multiple operational zones, including normal, caution, and alarm.
- Gradient: The magnitude across two categorical dimensions, communicated by a continuous interpolated scale of colors. This chart is best for data with no natural breakpoints.
Propertiesβ
| Name | Description | Property Type |
|---|---|---|
| data | The dataset powering the chart. Each row is one cell. The xField and yField categories represent the cells and valueKey represents the magnitude. Options include:
| array |
| xAxis | Configures the x-axis category. See xAxis Properties for more object properties. | object |
| yAxis | Configures the y-axis category. See yAxis Properties for more object properties. | object |
| visualMap | Maps each cell's value to a color. See visualMap Properties for more object properties. | object |
| dataLabels | Configures the value label rendered inside each cell. Options include:
| object |
| title | Configures the chart title and subtitle, including options for text, styling, and layout customization. See title Properties for more object properties. | object |
| tooltip | The tooltip shown on hover. See tooltip Properties for more object properties. | object |
| appearance | Configures chart-level visuals. See appearance Properties for more object properties. | object |
| style | Styles defined within the Project to be applied to this component. | object |
xAxis Propertiesβ
| Name | Description | Property Type |
|---|---|---|
| visible | Shows the x-axis when true. Default is true. | boolean |
| title | The name of the x-axis, shown alongside tick labels. Options include:
| object |
| position | Determines whether data renders along the top or bottom of the x-axis. Default is bottom. | string |
| labels | Configures the tick value label text. Options include:
| object |
yAxis Propertiesβ
| Name | Description | Property Type |
|---|---|---|
| visible | Shows the y-axis when true. Default is true. | boolean |
| title | The name of the y-axis, shown alongside tick labels. Options include:
| object |
| position | Determines whether data renders to the right or left of the y-axis. Default is left. | string |
| labels | Configures the tick value label text. Options include:
| object |
visualMap Propertiesβ
| Name | Description | Property Type |
|---|---|---|
| mode | The differentiator between the Heatmap variants. Setting the mode to either grid or gradient will swap between one of the two variants. | string |
| emptyColor | The fill color for empty or non-numeric cells. Leave empty to draw no cell. Note that the grid background will still show through the cell when not drawn. | color |
| pieces | A list of ordered value ranges and their colors. Only applies to the Grid variant. List order matters, as the last entry will treat max as inclusive. Leave empty to use the theme default color ramp.
| array |
| invert | Reverses the color mapping when true. Only applies to the Gradient variant. Default is false. | boolean |
| min | Minimum value of the color scale. Only applies to the Gradient variant. Can be a number, or leave empty to fit the provided data. | numeric |
| max | Maximum value of the color scale. Only applies to the Gradient variant. Can be a number, or leave empty to fit the provided data. | numeric |
| gradient | Colors used for the Gradient variant's continuous color ramp. Only applies to the Gradient variant. Color ramp includes endpoint colors plus optional interior stops. Colors can be chosen from the color wheel, color palette, or entered as RGB or HSL values. See Color Selector. Options include:
| object |
| legend | The color-scale legend shown alongside the grid. The Grid variant renders individual color band swatches, while the Gradient variant renders a continuous color bar. Options include:
| object |
title Propertiesβ
| Name | Description | Property Type |
|---|---|---|
| visible | Shows the title of the chart when true. | boolean |
| text | The main title text. | string |
| color | Color of the main title text. Takes precedence over elementStyle.color when both are set. Can be chosen from color wheel, chosen from color palette, or entered as RGB or HSL value. See Color Selector. | color |
| fontSize | The font size of the main title text. Takes precedence over elementStyle.fontSize when both are set. | numeric |
| subtitle | Configures the subtitle displayed below the main title. Options include:
| object |
| position | The position of the title within the chart. | string |
| gap | The gap in pixels between the main title and subtitle. | numeric |
| elementStyle | Text style for a label rendered onto a chart canvas, including typography, alignment, optional box styling, and shadow. | object |
tooltip Propertiesβ
| Name | Description | Property Type |
|---|---|---|
| enabled | Shows the tooltip on hover when true. | boolean |
| formatter | Sets the tooltip display format. Options include:
| object |
appearance Propertiesβ
| Name | Description | Property Type |
|---|---|---|
| borderWidth | Width of each cell's border in pixels. Set to 0 to remove cell borders. | numeric |
| borderColor | Cell border color. Leave empty to use the default theme. Can be chosen from color wheel, chosen from color palette, or entered as RGB or HSL value. See Color Selector. | color |
| borderRadius | Corner radius of each cell in pixels. | numeric |
| backgroundColor | Background fill for the entire chart component. Leave empty for transparent. Can be chosen from color wheel, chosen from color palette, or entered as RGB or HSL value. See Color Selector. | color |
| highlight | Configures cell styling when hovered over or highlighted by the legend. Options include:
| object |
| animation | Configures chart-level entry and transition animation. Options include:
| object |
Component Scripts and Eventsβ
Further component interaction and functionality can be configured for all components through scripting and event actions. Right-click on the component or select Components from the Designer menubar to access the configuration popups for both of these options:
- Configure Events: Accesses the Event Configuration popup where you can configure actions to run in response to events to make the component dynamic. The Events Configurations page shows how to configure events and actions on a Perspective component.
- Configure Scripts: Accesses the Script Configuration popup where custom methods and message handlers can be added. The Scripting in Perspective section details scripting fundamentals, creating custom methods, and using message handlers.
The Heatmap component also has Component Events associated with it. See the Heatmap - Line Scripting page for more information.
Examplesβ
Grid Exampleβ

This example showcases color-coded values across the same days at different times using a Grid variant. The sample data used in this example is listed below in JSON format.
[
{
"props": {
"data": [
{
"hour": "00:00",
"day": "Mon",
"value": 87
},
{
"hour": "00:00",
"day": "Tue",
"value": 91
},
{
"hour": "00:00",
"day": "Wed",
"value": 78
},
{
"hour": "01:00",
"day": "Mon",
"value": 83
},
{
"hour": "01:00",
"day": "Tue",
"value": 95
},
{
"hour": "01:00",
"day": "Wed",
"value": 64
}
],
"xField": "hour",
"yField": "day",
"xAxis": {
"title": {
"text": "Hour"
},
"labels": {
"fontSize": 12
}
},
"yAxis": {
"title": {
"text": "Day"
},
"labels": {
"fontSize": 12
}
},
"visualMap": {
"emptyColor": "#E6E6E6",
"pieces": [
{
"min": 85,
"max": "",
"color": "#2DB87A",
"label": "World Class"
},
{
"min": 65,
"max": 85,
"color": "#E0A020",
"label": "Acceptable"
},
{
"min": "",
"max": 65,
"color": "#D84C3F",
"label": "Needs Improvement"
}
],
"legend": {
"orientation": "vertical",
"wrapLabels": false,
"gap": 80,
"fontSize": 12
}
},
"appearance": {
"borderWidth": 1,
"borderColor": "#FFFFFF"
}
}
}
]
Gradient Exampleβ

This example showcases how color-coded statuses could display across different zones on a factory floor using a Gradient variant. The sample data used in this example is listed below in JSON format.
[
{
"props": {
"data": [
{
"value": 42.3,
"x": "Zone A",
"y": "Sensor 1"
},
{
"x": "Zone A",
"y": "Sensor 2",
"value": 67.8
},
{
"x": "Zone B",
"y": "Sensor 1",
"value": 88.1
},
{
"x": "Zone B",
"y": "Sensor 2",
"value": 31.4
}
],
"xAxis": {
"labels": {
"fontSize": 12
}
},
"yAxis": {
"labels": {
"fontSize": 12
}
},
"visualMap": {
"mode": "gradient",
"emptyColor": "#E6E6E6",
"min": 0,
"max": 100,
"gradient": {
"colorLow": "#1A5FAD",
"colorHigh": "#E8590C"
},
"legend": {
"orientation": "vertical"
}
},
"appearance": {
"borderWidth": 1,
"borderColor": "#FFFFFF"
}
}
}
]