INNER CODE UNIT · JavaScript
createVisualization
KeepSafe/dexcount-gradle-plugin · src/main/resources/com/getkeepsafe/dexcount/chart-builder.js:87
function createVisualization(data) {
// Basic setup of page elements.
initializeBreadcrumbTrail();
// Bounding circle underneath the sunburst, to make it easier to detect when the mouse leaves the parent g.
vis.append("svg:circle")
.attr("r", radius)
.style("opacity", 0);
// For efficiency, filter nodes to keep only those large enough to see.
var nodes = partition.nodes(data)
.filter(function (d) {
return (d.dx > 0.005); // 0.005 radians = 0.029 degrees
});
var path = vis.data([data]).selectAll("path")
.data(nodes)
.enter().append("svg:path")