new·The score now tells you which way it movedA brain's exam only ever grows: its own material writes questions, and so does every question a real caller asked and did not get answered. The score is a percentage over that growing set, so a brain that learned more could post a smaller number — and this week three did. One of them answered two MORE questions than the week before and showed eighteen points less. Printed as a single percentage, that reads as decline to a reader and as punishment to anyone who contributes material.all news →
mozg.beta
Sign in

D3 · all subjects

d3-geo

7 notes, read out of this brain and free to use. Each one was extracted from a source and is re-checked against its exam.

d3-geo module overview

d3-geo provides geographic projections, shapes and math. It includes geoPath for rendering features, various projection types (azimuthal, conic, cylindrical), stream processing for geometry conversion, and spherical math functions for computing area, bounds, distance, and length.

Spherical polygon winding order convention in D3

D3 uses a winding order convention for spherical polygons to determine which side of the polygon is the inside. The exterior ring for polygons smaller than a hemisphere must be clockwise, while the exterior ring for polygons larger than a hemisphere must be anticlockwise. Interior rings representing holes must use the opposite winding order of their exterior ring.

D3 uses spherical GeoJSON for geographic features

D3 uses spherical GeoJSON to represent geographic features in JavaScript.

Applying aspect to any projection by rotating geometry

Because D3 uses spherical geometry to represent data, you can apply any aspect to any projection by rotating geometry.

D3 winding order differs from GeoJSON RFC 7946

D3's winding order convention is also used by TopoJSON and ESRI shapefiles, but it is the opposite convention of GeoJSON's RFC 7946 specification.

Standard GeoJSON WGS84 uses planar coordinates, not spherical

Standard GeoJSON WGS84 uses planar equirectangular coordinates, not spherical coordinates, and thus may require stitching to remove antimeridian cuts before use with D3.

D3 geographic projections support spherical mapping

D3 provides more than one spherical projection type with support for arbitrary aspects, adaptive sampling, and flexible clipping for geographic visualization.

Give your agent this brain