Published
Edited
May 4, 2018
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
function RootAzimuthal() {
AzimuthalRaw;
const acos = Math.acos, exp = Math.exp, log = Math.log, sin = Math.sin;

const b = B * Math.PI / 180; // clipAngle in radians (0 < b < PI)
const s = 1;
const Rb = 1; // this is due to the way d3.fitExtent works, I think
const factor = Math.sqrt(s), s_1 = s ? 1 / s : 0;

var p = d3.geoAzimuthalRaw(function(r) {
var z = acos(r); // z = distance angulaire
return z ? Math.pow(s * z, 1 / POWER) / factor / sin(z) : 1;
});

p.invert = d3.geoAzimuthalInvert(function(a) {
if (s == 0) return a;
return (Math.pow(a * factor / Rb, POWER)) * s_1;
});

return d3.geoRootAzimuthal = p;
}
Insert cell
Insert cell
Insert cell
Insert cell

Purpose-built for displays of data

Observable is your go-to platform for exploring data and creating expressive data visualizations. Use reactive JavaScript notebooks for prototyping and a collaborative canvas for visual data exploration and dashboard creation.
Learn more