This is the first of a set of data-driven expansions of The Nature of Code. The idea from chapter 0 is that the distribution of a random walker’s steps changes the whole picture. Instead of inventing a distribution, this one reads it off the planet.

The page fetches the USGS feed of every magnitude 2.5+ earthquake in the past week and sorts them by time. Each frame, the walker takes a step whose length is roughly 10^(mag - 2.5), because seismic energy grows exponentially with magnitude. Most quakes are small and the walker shuffles locally; a rare large one throws it across the canvas and leaves a thin thread behind. That is a Lévy flight, and here the leaps are real events rather than a tuned probability.

Data source: USGS Earthquake Hazards Program
Endpoint: https://earthquake.usgs.gov/earthquakes/feed/v1.0/summary/2.5_week.geojson
Access: Public, no key. Loaded from an hourly server-side refresh when possible, with a bundled snapshot fallback, and a live browser fetch only when the API allows CORS. Data window: Jul 11, 2026 - Jul 18, 2026 (pulled Jul 18, 2026 UTC)

The status line says whether the earthquakes were fetched live or loaded from the saved snapshot bundled with the page, so it still runs if the API is unreachable.