Public
Edited
Mar 3, 2023
Insert cell
Insert cell
import {us} from "@observablehq/us-geographic-data"
Insert cell
Insert cell
tooltip = d3.select('body')
.append('div')
.attr('class', 'tooltip')
.style('position', 'absolute')
.text('test')
Insert cell
path = d3.geoPath().projection(projection);
Insert cell
projection = d3.geoIdentity().fitSize([width, height], stateData[0]);
Insert cell
stateData = topojson.feature(usData, usData.objects.states).features.filter((d) => d.id === "33");
Insert cell
usData = await d3.json('https://d3js.org/us-10m.v2.json')
Insert cell
countiesData = topojson.feature(usData, usData.objects.counties).features;
Insert cell
d3 = require("d3@5")
Insert cell
topojson = require('topojson-client@3')
Insert cell
height = 600
Insert cell
width = 960
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