solarnetwork-d3.js
function(location) {
      return Math.sqrt(Math.pow(location.x - this.matrix[4], 2), Math.pow(location.y - this.matrix[5], 2));
    }
function(location) {
      return Math.sqrt(Math.pow(location.x - this.matrix[4], 2), Math.pow(location.y - this.matrix[5], 2));
    }
function ( location ) { return Math . sqrt ( Math . pow ( location . x - this . matrix [ 4 ] , 2 ) , Math . pow ( location . y - this . matrix [ 5 ] , 2 ) ) ; }
Get the 2D distance between a location and this matrix's translation.

@param location a location object, with x,y Number properties
@returns {Number} the calculated distance
@preserve
Get the 2D distance between a location and this matrix s translation .