liveBook · Manning

Latitude

As explained in D3.js in Action, Third Edition

Latitude is the angular coordinate specifying a north–south position relative to the equator on Earth.

Latitude is the horizontal geographic coordinate that measures distance north or south of the equator. Together with longitude, it locates a point on Earth. section 13.1.1

When mapping data with D3, latitude is used as part of a coordinate pair:

  • Store a location as [longitude, latitude], such as a city’s birth coordinates. section 13.2.4
  • Pass the pair to a projection, which converts the geographic position into SVG x and y coordinates. section 13.7

Plotting birth cities

A Nobel laureate map can retain each city’s latitude and longitude, pass them through a D3 projection, and draw a circle at the returned position. Circle radius can then represent how many laureates were born there. section 13.2.4

const projection = d3.geoEqualEarth();

[x, y] = projection([longitude, latitude]);

This compact pattern shows latitude in its practical role: the second value in a [longitude, latitude] pair sent to a D3 projection. section 13.2.4

How D3.js in Action, Third Edition covers it

How deep it goes
Defines north–south position and demonstrates projected point placement, while deferring detailed GeoJSON geometry construction.
Examples
Uses GeoJSON polygon coordinates and Nobel laureates’ birth-city locations as concrete mapping examples.
What it assumes
Assumes basic coordinate pairs and geographic maps while defining latitude alongside longitude.
What you can do after
Apply it via a D3 projection to position geographic points inside an SVG map.
How it connects
Connects latitude with longitude, geographic projections, GeoJSON, TopoJSON, D3, and SVG map rendering.

Also explained in

Compare how 2 books explain latitude →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of D3.js in Action, Third Edition. The section links point to the parts of the book it draws on.