Published
Edited
Feb 22, 2020
Fork of Hills
1 star
Insert cell
Insert cell
{
for (const dy of [.1, .15, .2, .25, .3, .35]) {
const y = dy * height
const data = generate(y, y + 30, 20, 50);
g.append('path')
.attr('d', `M${data.map((y, i) => `${y * Math.cos(i / data.length * 360)},${y * Math.sin(i / data.length * 360)}`).join(' ')}`)
.attr('fill', 'tomato')
.attr('opacity', .3)
}
return svg.node()
}
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
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