HTML/JavaScript Code
The HTML elements and JavaScript code used in this example.
...
<div id="chartDiv"></div>
...
function showChart()
{
let config = {
title: "Contoso Sales Historical - Desktop vs Laptops",
width: "800",
height: "600",
darkMode: true,
thousandsSeparator: ".",
decimalSeparator: ",",
transitionTime: 3,
countryFlags: true,
showAxisImages: true,
measures: [{ title: "Sales", prefix: "$"}],
groups: ["Store", "Online"],
csvType: "rowItems",
dataCSVURL: "/charts/examples/contosoByCountry.csv",
}
kyubitTimeCharts.showButterflyChart("chartDiv", config);
}
Learn more about
Animated Butterfly Chart API.