anychart.onDocumentReady(function () { // The data used in this sample can be obtained from the CDN // https://cdn.anychart.com/samples/tag-cloud/programming-languages-and-libraries-by-age/data.json anychart.data.loadJsonFile( '/static/json/keyphrase.json', function (data) { // add age for each library for (var i = 0; i < data.length; i++) { data[i].value = data[i]['rank']; } var dataSet = anychart.data.set(data); var colors = anychart.scales .linearColor() .colors(['#000']); // create tag cloud var chart = anychart.tagCloud(); // set the mode of the tag cloud chart.mode("spiral"); // chart.normal().fill("#1fadad"); chart.hovered().fill("#93bfec"); // chart.selected().fill("#1f66ad"); // chart.normal().stroke("#0f5757"); // chart.hovered().stroke("#0f3357"); // chart.selected().stroke("#0f3357"); // chart.normal().fontWeight(600); // chart.normal().fontSize(12) // set chart title chart .title() .enabled(true) .useHtml(true) .text( '