Public
Edited
Jan 17, 2024
Paused
1 fork
11 stars
Insert cell
Insert cell
Insert cell
Insert cell
Plot.plot({
marks: [
Plot.cell(colors, {
x: "a",
y: "b",
fill: (d) => d,
...(sRGB.length ? { fillOpacity: (d) => d.displayable() } : {}),
inset: -1
}),
Plot.crosshair(colors, {
x: "a",
y: "b",
}),
],
color: { type: "identity" },
y: { reverse: true },
opacity: { domain: [true, false], range: [1, 0.3] },
width,
height: width,
marginRight: 0,
marginTop: 0
})
Insert cell
colors = d3
.cross(d3.range(-80, 100, 5), d3.range(-110, 100, 5))
.map(([a, b]) => d3.lab(l, a, b))
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