Skip to content

v0.1: interactive 3D and 2D hexagon maps from a MapSpec - #1

Merged
yamierick merged 1 commit into
mainfrom
v0.1
Sep 27, 2026
Merged

yamierick merged 1 commit into
mainfrom
v0.1

Conversation

@yamierick

Copy link
Copy Markdown
Contributor

The lab's interactive hexagon maps, extracted from sear-labs/tarrant-landvalue-gis (where they were built and checked in a browser) and made reusable.

What it does

A project bins its data into equal-area hexagons, describes the map as a MapSpec, and gets two self-contained HTML pages:

  • 3D (write_3d): deck.gl 9.4.0 columns over a MapLibre 5.24.0 basemap (CARTO, no token).
    • Compass that resets to north; zoom, tilt and fit buttons.
    • Falls back to a plain ground where the basemap can't load (for example, a Claude Artifact).
  • 2D (write_2d): zoomable SVG (wheel, drag, pinch), with light and dark themes.
  • Both:
    • darker = higher on every background;
    • hexagon cards show values, a split bar, and the named areas covering the hexagon;
    • "Click to inspect" for any area layer;
    • outlines with a ranked list;
    • roads, water and place labels.

Reusable, not Tarrant-shaped

  • Every word and number on a page comes from the spec; formatting is done in Python (fmt).
  • A test fails if a project's name appears in the templates.
  • examples/synthetic_map.py builds a complete map from made-up data, with no downloads, and is the end-to-end test.

Checks

  • 16 tests and ruff pass locally.
  • Both synthetic pages were rendered in a browser with no console errors.
  • The Tarrant maps rebuilt on this library reproduce the earlier cards exactly (for example, Fort Worth District 11 at $1,070 per resident; a District 9 hexagon at $19,037 per acre, in Tract 1020, ZIP 76107).

For Dr. Jones

  • Private for now. tarrant-landvalue-gis's CI can't install a private package from another private repo without a token. So tarrant installs it as an optional extra, used only by its map script, and tarrant's tests don't need it. Making this repo public, since it is generic code with no data, would remove that wrinkle. That's your call.
  • Name. hexmap-web follows the standard's subject-method form. Rename now if it's going to be renamed; it gets costlier after the first release tag.

🤖 Generated with Claude Code

Extracted from sear-labs/tarrant-landvalue-gis and made generic: a project bins its data
(hexbin), describes the map (spec.MapSpec: metrics, views, card fields, split, inspectable
area layers, outlines with rankings, roads/water/places) and writes the pages (page.write_3d:
deck.gl 9.4.0 over MapLibre 5.24.0; page.write_2d: zoomable SVG). All wording and number
formats come from the spec; a test fails if a project's name reaches the templates.
examples/synthetic_map.py builds a complete map from made-up data and is the end-to-end test.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@yamierick
yamierick merged commit 27e0e7d into main Sep 27, 2026
1 check passed
@yamierick
yamierick deleted the v0.1 branch September 27, 2026 15:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant