Public
Edited
Apr 1
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
// A time-based scale that allows for a dynamic number of tick labels depending on the available width
xTime = d3
.scaleUtc()
.domain(paddedExtent)
.range([
chartDimensions.margin.left,
chartDimensions.width - chartDimensions.margin.right
])
Insert cell
// A scale band for positioning the bars on the x-axis
xBand = d3
.scaleBand()
.domain(d3.timeYear.range(...xTime.domain()))
.range([
chartDimensions.margin.left,
chartDimensions.width - chartDimensions.margin.right
])
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
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