Public
Edited
Sep 18, 2023
Insert cell
Insert cell
data = (
await fetch(
"https://raw.githubusercontent.com/felixge/pprofutils/main/examples/json.out.json"
)
).json()
Insert cell
import { vl } from "@vega/vega-lite-api-v5"
Insert cell
Type JavaScript, then Shift-Enter. Ctrl-space for more options. Arrow ↑/↓ to switch modes.

Insert cell
data.Sample.flatMap(({ Value, Location }, sampleIndex) =>
Location.map((d) => ({ sampleIndex, ...d, v0: Value[0], v1: Value[1] }))
)
Insert cell

Purpose-built for displays of data

Observable is your go-to platform for exploring data and creating expressive data visualizations. Use reactive JavaScript notebooks for prototyping and a collaborative canvas for visual data exploration and dashboard creation.
Learn more