An indicator represents a phenomenon that can be displayed on a map. It allows the user to configure how the phenomenon will be displayed. Indicator has a reference to a metric, which is a mathematical expression of the phenomenon. Indicators are further analysed in indicator drills, with whom they are paired with and displayed in a dashboard.
...
Code Block | ||||
---|---|---|---|---|
| ||||
{ "name": "turnover_indicator", "type": "indicator", "title": "Turnover value", "description": "Total turnover of all purchases. It indicates how much money your customers have spent.", "content": { "metric": "/rest/projects/$projectId/md/metrics?name=turnover_metric", "scale": "standard", "distribution": "geometric", "visualizations": { "heatmap": true, "dominance": true }, "format": { "type": "number", "fraction": 0, "symbol": "£" }, "scaleOptions": { "static": [ { "dataset": "/rest/projects/$projectId/md/datasets?name=postcodes", "breaks": { "global": [ 10000, 20000, 40000, 80000 ], "selection": [ 1000, 2000, 4000, 8000 ] }, "maxValues": [ { "zoom": 18, "global": 100000, "selection": 10000, "itemId": "05f174e2300cee630980bdc3166cce7f" } ], "itemId": "05f174e2300cee630980bdc3166cce7f" } ] } } } |
This indicator has the content.scaleOptions.static
object set. Few points to note:
...
areas
(based ongeometryPolygon
subtype dataset)
(based ongrid
geometryPolygon
subtype dataset)
(based onzones
geometryPolygon
subtype dataset)heatmap
(based ongeometryPoint
subtype dataset)dotmap
(based ongeometryPoint
subtype dataset)line
(based ongeometryLine
subtype dataset)
| grid | zones | heatmap | dotmap | line |
---|---|---|---|---|---|
This object also allows to enable the Dominance visualization in the Compare tool ().
...
Key | Type | Optionality | Description | Constraints | |||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
dataset | string |
| URL link to the dataset representing a granularity, on which the breaks will be applied only if not specified, the breaks will be applied to all datasets (all granularities) | /rest/projects/$projectId/md/datasets?name={datasetName} | |||||||||||||||||||
breaks | object |
| object representing the break values | ||||||||||||||||||||
maxValues | array |
| array of maximal values for the heatmap visualization scale | x => 0 | itemId | string |
| Generated ID for this item to be used for matching it within a parent array while rebasing share objects. For more details see content.**.itemId section. | [a-z0-9]{32} |
content.scaleOptions.static.breaks
...
Key | Type | Optionality | Description | Constraints | ||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
zoom | integer |
| zoom level, for which the no need to specify all 16 zoom levels - when one level is specified, the rest is computed as a result of a geometric series |
| ||||||||
global | decimal |
| global scale value (= no marker selected) |
| ||||||||
selection | decimal |
| selected scale value (= when a marker is selected) | x => 0.0 | ||||||||
itemId | string |
| Generated ID for this item to be used for matching it within a parent array while rebasing share objects. For more details see content.**.itemId section. | [a-z0-9]{32} |
content.scaleOptions.defaultDistribution
...
content.scaleOptions.defaultDistribution
This object allows you to set the default values (including outer breaks) of the indicator's corresponding indicator drill's distribution
block. These settings are reset when a filter is applied.
Key | Type | Optionality | Description | Constraints | ||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
breaks | array |
| array of distribution break values (integer or decimal) |
| ||||||||
displayIntervals | array |
| specifies which scale intervals should be displayed |
content.**.itemId
Generated ID for this item to be used for matching it within a parent array while rebasing share objects. itemId is genrated as hash from random UUID when given item is being created - either an entire dashboard is being created or an item is being added to MD object content via update. Once itemId is generated it is not supposed to be modified.
IMPORTANT: When interacting with REST API do not provide own generated values as itemId;
...
Visual representation
Indicators are represented as a list of cards in a dashboard.
...