Published unlisted
Edited
Oct 3, 2019
Insert cell
Insert cell
scaled_data = [[100, 17113.1], [100.001, 17113.1], [300, 17113.1]]
Insert cell
delaunay = d3.Delaunay.from(scaled_data)
Insert cell
[...delaunay.neighbors(0)]
Insert cell
[...delaunay.neighbors(1)]
Insert cell
[...delaunay.neighbors(2)]
Insert cell
delaunay.find(300, 17113.1) // returns 0 but should return 5
Insert cell
d3 = require("d3-delaunay@5" ||
"http://localhost/d3/d3-delaunay/dist/d3-delaunay.js?@5" + Math.random())
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