Tree Chart with HTML nodes

Type tutorial

This tutorial shows how we can use HTML content instead of built-in circle nodes on a Tree Chart.

Hybrid line and Gantt chart

Type tutorial

This demo shows how we can use stacked axes to create a combined chart with a Line series and Column (Gantt) series sharing the same X axis.

Adding amCharts to Squarespace

Type tutorial

This tutorial will show how we can easily add an amCharts 5 chart to a Squarespace page. Requirements This tutorial assumes you have a basic understanding of how amCharts 5 works and how to create a code for it. It also utilizes premium feature of Squarespace – JavaScript embedding – which means you will need […]

Handling long category axis labels

Type tutorial

This tutorial looks at ways on how to handle situations where labels of a CategoryAxis are too long to comfortably fit. Wrapping or truncating This sections shows how we can use an event and oversizeBehavior on axis labels, to make them auto-wrap automatically. The above code uses axis’ event of cellWidth (which reports whenever cell width is changed) […]

Selectively positioning Sankey diagram labels

Type tutorial

It’s possible to selectively specify the location of Sankey diagram labels, based on the position of their parent Nodes. This tutorial will show how. Moving labels We’re going to use an adapter to dynamically change value of a label’s centerX setting. If the node is a left-most node (does not have any incoming links) we’ll position […]

Bubble chart with zoom in and out buttons

Type tutorial

This demo shows how we can add plus/minus buttons to a bubble chart that zoom in and out the chart. Code The code relies on adding custom buttons to chart plot container, as well as attaching click events to them, that in turn zoom the chart using axis’ API. Demo

Daisy-chain multiple chart rendering

Type tutorial

This tutorial shows how we can implement a simple daisy-chain to render multiple charts one at a time, with a custom delay. This approach might help ease the initial load on a chart-heavy pages. Implementing the queue The idea is this: instead of creating a chart instantly, we wrap it into a function and push […]