Skip to content
A

Live: ProfileViewer

Loading the Python runtime…Running the notebook cells…

This page runs Python in your browser through marimo WebAssembly islands, like the CPTViewer example. The first run downloads the Python runtime and the packages, which can take a minute.

Fetch the soundings

Four public CPTs along a line, fetched from the BRO API with brodata, listed in profile order:

Stack the soundings in one long table

ProfileViewer takes tidy long data: every CPT’s samples in one table, with a name column telling them apart. Each CPT’s elevation comes from its own surface offset, so the strips line up in NAP:

Anchor the strips

chainage turns each CPT’s map coordinates into a distance along the profile line:

Pick the channels

Every strip plots the same channels. As in the CPTViewer example, the multiselect is a marimo UI element: the viewer cell reads its value, so changing the selection redraws the profile.

Show the profile

The toolbar toggle switches between true-scale chainage and equal spacing. Zoom and pan work as in the CPTViewer example, and a click selects a strip, syncing its name back to Python through the selected trait.

The ProfileViewer reference covers the rest: channel bindings for other column names, interpretation backdrops behind the curves, and profile-space overlays such as a surface line or a groundwater level.