Public
Edited
Sep 20, 2023
1 star
Insert cell
Insert cell
Plot.plot({
projection: ternary.projection,
inset: 25,
color: { type: "identity" },
marks: [
Plot.raster(
d3
.cross(d3.ticks(0, 1, 20), d3.ticks(0, 1, 20))
.filter(([x, y]) => x + y <= 1),
{
fill: color,
interpolate: "random-walk",
pixelSize: 1,
blur: 3,
clip: "sphere"
}
),
Plot.sphere(),
Plot.dot([a, b, c], {
fill: Plot.identity,
x: [1, 0, 0],
y: [0, 1, 0],
r: 20
})
]
})
Insert cell
Insert cell
Insert cell
Insert cell
color = ([x, y]) => spectral.mix(spectral.mix(c, a, x / (1.0001 - y)), b, y)
Insert cell
spectral = require("spectral.js@2")
Insert cell
import { ternary } from "@fil/ternary-plot"
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