|
|
@ -185,7 +185,7 @@ export default { |
|
|
|
.style("visibility", "hidden"); |
|
|
|
.style("visibility", "hidden"); |
|
|
|
// define the zoomListener which calls the zoom function on the "zoom" event constrained within the scaleExtents |
|
|
|
// define the zoomListener which calls the zoom function on the "zoom" event constrained within the scaleExtents |
|
|
|
const zoom = d3.zoom() |
|
|
|
const zoom = d3.zoom() |
|
|
|
.scaleExtent([0.1, 3]) //zoom limit |
|
|
|
.scaleExtent([0.4, 3]) //zoom limit |
|
|
|
.on('zoom', () => { |
|
|
|
.on('zoom', () => { |
|
|
|
svg.attr('transform', d3.event.transform) // updated for d3 v4 |
|
|
|
svg.attr('transform', d3.event.transform) // updated for d3 v4 |
|
|
|
}) |
|
|
|
}) |
|
|
@ -223,7 +223,7 @@ export default { |
|
|
|
.call(zoom) |
|
|
|
.call(zoom) |
|
|
|
//.call(zoom.transform, d3.zoomIdentity.translate(200, 20).scale(0.25)) //initial size |
|
|
|
//.call(zoom.transform, d3.zoomIdentity.translate(200, 20).scale(0.25)) //initial size |
|
|
|
.append('svg:g') |
|
|
|
.append('svg:g') |
|
|
|
.attr("transform", "translate(" + viewerPosLeft + "," + viewerPosTopHeat + ")"); |
|
|
|
.attr("transform", "scale(1.5,1.5) translate(" + viewerPosLeft + "," + viewerPosTopHeat + ")"); |
|
|
|
|
|
|
|
|
|
|
|
svg.append('defs') |
|
|
|
svg.append('defs') |
|
|
|
.append('pattern') |
|
|
|
.append('pattern') |
|
|
@ -324,8 +324,8 @@ export default { |
|
|
|
return d.idx; |
|
|
|
return d.idx; |
|
|
|
}) |
|
|
|
}) |
|
|
|
.attr("class", "row"); |
|
|
|
.attr("class", "row"); |
|
|
|
svg.append("text").attr("x", 10).attr("y", -65).text("Technique").style("font-size", "16px").attr("alignment-baseline","top") |
|
|
|
svg.append("text").attr("x", 10).attr("y", -65).text("Technique").style("font-size", "14px").attr("alignment-baseline","top") |
|
|
|
svg.append("text").attr("transform", "rotate(-90)").attr("x", (-1)*(cellSize*(len/2))).attr("y", -75).style("text-anchor", "middle").style("font-size", "16px").text("Feature"); // -130 before for HeartC |
|
|
|
svg.append("text").attr("transform", "rotate(-90)").attr("x", (-1)*(cellSize*(len/2))).attr("y", -75).style("text-anchor", "middle").style("font-size", "14px").text("Feature"); // -130 before for HeartC |
|
|
|
var heatMap = row.selectAll(".cell") |
|
|
|
var heatMap = row.selectAll(".cell") |
|
|
|
.data(function(d) { |
|
|
|
.data(function(d) { |
|
|
|
return d; |
|
|
|
return d; |
|
|
|