Uncaught TypeError: Cannot read property 'linear' of undefined In D3 v4 it is no longer named d3.scale.linear(). Use d3.scaleLinear() instead.