Commits

Mark Howison committed c6b4830

report: use bold stroke to indicate current assembly in trace animation

Comments (0)

Files changed (1)

 var y;
 
 function clear_state() {
-  assembly.selectAll(".node").selectAll("ellipse").attr("stroke", "grey");
-  assembly.selectAll(".edge").selectAll("path").attr("stroke", "grey");
+  assembly.selectAll(".node").selectAll("ellipse").attr("stroke", "grey").attr("stroke-width", "2");
+  assembly.selectAll(".edge").selectAll("path").attr("stroke", "grey").attr("stroke-width", "2");
 }
 
 function color_state() {
+  for (var j=0; j<node_frequencies[i].length; j++) {
+    var color = colormap(node_frequencies[i][j]);
+    assembly.select("#node"+j).selectAll("ellipse").attr("stroke", color);
+  }
   for (var j=0; j<nodes[i].length; j++) {
-    var color = colormap(node_frequencies[i][nodes[i][j]]);
-    assembly.select("#node"+nodes[i][j]).selectAll("ellipse").attr("stroke", color);
+    assembly.select("#node"+nodes[i][j]).selectAll("ellipse").attr("stroke-width", "6");
+  }
+  for (var j=0; j<edge_frequencies[i].length; j++) {
+    var color = colormap(edge_frequencies[i][j]);
+    assembly.select("#edge"+j).selectAll("path").attr("stroke", color);
   }
-  for (var j=0; j<edges[i].length; j++) {
-    var color = colormap(edge_frequencies[i][edges[i][j]]);
-    assembly.select("#edge"+edges[i][j]).selectAll("path").attr("stroke", color);
+  for (var j=0; j<edges[i].length; j++) {    assembly.select("#edge"+edges[i][j]).selectAll("path").attr("stroke-width", "4");
   }
 }