chart = {
const svg = d3.select(DOM.svg()).attr("viewBox", [0, 0, width, height]);
svg.selectAll('.row')
.data(data)
.enter()
.append('g')
.attr('transform', (d, i) => `translate(0, ${i * cellWidth})`)
.selectAll('.cell')
.data((d, i) => data[i])
.enter()
.append('rect')
.attr("width", cellWidth)
.attr('height', cellWidth)
.attr('x', (d, i) => i * cellWidth)
.attr('stroke', 'white')
.attr('stroke-width', '1px')
.attr('fill', d => `rgb(255, ${(-d + 1) / 2 * 200}, 0)`)
return svg.node()
}