Published
Edited
Jul 9, 2021
1 fork
Insert cell
Insert cell
Insert cell
Insert cell
0
Insert cell
Insert cell
Insert cell
Insert cell
anotherColorScale = d3
.scaleLinear()
.domain([50, 75, 85, 100])
.range(['#FF6666', '#ECF1C9', '#7DD9A2', '#71DAB4'])
Insert cell
scale = d3
.scaleLinear()
.domain([55, 100])
.range([.30, .82])
// .clamp(true)
Insert cell
Insert cell
customScale = d3
.scaleLinear()
.domain([55, 70, 100])
.range(['#D45B41', '#D7EB96', '#5AA35F'])
Insert cell
Insert cell
zoneScale = d3
.scaleLinear()
.domain([0, 1440])
.range([0, 382])
Insert cell
zoneScale(120)
Insert cell
reducer = (accumulator, currentValue) => accumulator + currentValue
Insert cell
diverging = d3.scaleSequential(d3[`interpolate${scheme}`])
Insert cell
users = Array.from(d3.group(userData, d => d.user_id))
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
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