Skip to content

Icicle

Explore hierarchy through proportional stacked rectangles.

Chart ID: icicle. Independent import: @revolist/charts/icicle.

Loading chart…

Read hierarchy through nested horizontal bands. Band width conveys weight while vertical levels distinguish parents from descendants in the supported hierarchy view.

Supply semantic hierarchy paths and numeric weights. Treemap and sunburst can render complete trees; icicle and circle packing use their supported hierarchy projections. Hierarchy fields, IDs and labels must describe the same paths.

Use non-negative values for this chart. Negative values are rejected; explicit nulls represent missing observations.

The roles below describe the chart's data contract. Generic category/value roles resolve from the dataset; explicitly bind specialized numeric roles as shown in the complete example.

Data roleField count
hierarchy1 or more
weight1

Download the complete sample data and settings (JSON). See Data & Configuration for mapping, null values, updates and lifecycle rules.

Install the package using the installation guide, give the host an explicit height, and call createIcicleChart after the host mounts. This factory fixes the chart type to icicle.

<div id="chart" style="width: 100%; height: 450px;"></div>
Complete runnable TypeScript example with sample data
import { createIcicleChart } from '@revolist/charts/icicle';
const container = document.getElementById('chart')!;
const chart = await createIcicleChart({
container,
"dataset": {
"revision": 0,
"source": "client",
"categories": [
{
"id": "preview-category-0",
"label": "North",
"path": [
"North"
],
"labels": [
"North"
],
"depth": 1,
"kind": "group",
"hierarchy": {
"axis": "row",
"hierarchyId": "preview-row-hierarchy",
"levelId": "preview-region",
"levelIndex": 0,
"maxLevelIndex": 1,
"hasChildren": true,
"childCount": 3
}
},
{
"id": "preview-category-1",
"label": "South",
"path": [
"South"
],
"labels": [
"South"
],
"depth": 1,
"kind": "group",
"hierarchy": {
"axis": "row",
"hierarchyId": "preview-row-hierarchy",
"levelId": "preview-region",
"levelIndex": 0,
"maxLevelIndex": 1,
"hasChildren": true,
"childCount": 3
}
},
{
"id": "preview-category-2",
"label": "West",
"path": [
"West"
],
"labels": [
"West"
],
"depth": 1,
"kind": "group",
"hierarchy": {
"axis": "row",
"hierarchyId": "preview-row-hierarchy",
"levelId": "preview-region",
"levelIndex": 0,
"maxLevelIndex": 1,
"hasChildren": true,
"childCount": 3
}
},
{
"id": "preview-category-3",
"label": "East",
"path": [
"East"
],
"labels": [
"East"
],
"depth": 1,
"kind": "group",
"hierarchy": {
"axis": "row",
"hierarchyId": "preview-row-hierarchy",
"levelId": "preview-region",
"levelIndex": 0,
"maxLevelIndex": 1,
"hasChildren": true,
"childCount": 3
}
}
],
"series": [
{
"id": "preview-series-0",
"label": "Revenue",
"columnPath": [
"Revenue"
],
"labels": [
"Revenue"
],
"kind": "leaf",
"prop": "preview-0"
}
],
"values": [
[
48
],
[
34
],
[
28
],
[
16
]
],
"analyticalFrame": {
"fields": [
{
"id": "pivot:category",
"label": "pivot:category",
"role": "dimension",
"semanticType": "category"
},
{
"id": "pivot:series",
"label": "pivot:series",
"role": "dimension",
"semanticType": "category"
},
{
"id": "preview-series-0",
"label": "Revenue",
"role": "measure",
"semanticType": "number",
"sourceField": "preview-0"
}
],
"observations": [
{
"id": "[\"preview-category-0\",\"preview-series-0\"]",
"dimensions": {
"pivot:category": {
"value": "North",
"label": "North",
"path": [
"North"
],
"labels": [
"North"
]
},
"pivot:series": {
"value": "Revenue",
"label": "Revenue",
"path": [
"Revenue"
],
"labels": [
"Revenue"
]
}
},
"measures": {
"preview-series-0": 48
}
},
{
"id": "[\"preview-category-1\",\"preview-series-0\"]",
"dimensions": {
"pivot:category": {
"value": "South",
"label": "South",
"path": [
"South"
],
"labels": [
"South"
]
},
"pivot:series": {
"value": "Revenue",
"label": "Revenue",
"path": [
"Revenue"
],
"labels": [
"Revenue"
]
}
},
"measures": {
"preview-series-0": 34
}
},
{
"id": "[\"preview-category-2\",\"preview-series-0\"]",
"dimensions": {
"pivot:category": {
"value": "West",
"label": "West",
"path": [
"West"
],
"labels": [
"West"
]
},
"pivot:series": {
"value": "Revenue",
"label": "Revenue",
"path": [
"Revenue"
],
"labels": [
"Revenue"
]
}
},
"measures": {
"preview-series-0": 28
}
},
{
"id": "[\"preview-category-3\",\"preview-series-0\"]",
"dimensions": {
"pivot:category": {
"value": "East",
"label": "East",
"path": [
"East"
],
"labels": [
"East"
]
},
"pivot:series": {
"value": "Revenue",
"label": "Revenue",
"path": [
"Revenue"
],
"labels": [
"Revenue"
]
}
},
"measures": {
"preview-series-0": 16
}
}
],
"matrixCells": [
{
"categoryId": "preview-category-0",
"seriesId": "preview-series-0",
"observationId": "[\"preview-category-0\",\"preview-series-0\"]",
"measureFieldId": "preview-series-0"
},
{
"categoryId": "preview-category-1",
"seriesId": "preview-series-0",
"observationId": "[\"preview-category-1\",\"preview-series-0\"]",
"measureFieldId": "preview-series-0"
},
{
"categoryId": "preview-category-2",
"seriesId": "preview-series-0",
"observationId": "[\"preview-category-2\",\"preview-series-0\"]",
"measureFieldId": "preview-series-0"
},
{
"categoryId": "preview-category-3",
"seriesId": "preview-series-0",
"observationId": "[\"preview-category-3\",\"preview-series-0\"]",
"measureFieldId": "preview-series-0"
}
],
"hierarchies": {
"row": {
"id": "preview-row-hierarchy",
"axis": "row",
"levels": [
{
"id": "preview-region",
"field": "region",
"label": "Region",
"index": 0
},
{
"id": "preview-city",
"field": "city",
"label": "City",
"index": 1
}
]
}
}
},
"hierarchies": {
"row": {
"id": "preview-row-hierarchy",
"axis": "row",
"levels": [
{
"id": "preview-region",
"field": "region",
"label": "Region",
"index": 0
},
{
"id": "preview-city",
"field": "city",
"label": "City",
"index": 1
}
]
}
}
},
"bindings": {},
"presentation": {
"dataLabels": false
}
});
// When the host unmounts:
// chart.destroy();

Await updates before reading a snapshot or exporting. Call chart.destroy() when the host unmounts. See the live catalog to interact with this type.

Set these fields in chartOptions. The option schema validates supported keys, ranges and choices; updating chartOptions replaces that authored object.

OptionDefaultAccepted values
markOpacity10.2 to 1; step 0.05

Titles, legends, theme and labels belong to presentation or the corresponding top-level setting. Axis, color, navigation and interaction support depends on the selected chart; see Data & Configuration.

  • Treemap — Compare hierarchical values as proportional nested tiles.
  • Sunburst — Explore the current hierarchy level as proportional radial sectors.
  • Circle packing — Explore hierarchy through proportional nested circles.
  • Organization chart — Show connected parent and child cards.

Charts overview · Installation · Data & Configuration