addTooltips(
Plot.plot({
projection: "albers-usa",
marks: [
Plot.geo(counties, {
fill: (d) => broadband_access_2018.get(d.id),
title: (d) =>
`${d.properties.name} County \n ${percent(
broadband_access_2018.get(d.id)
)}`
}),
Plot.geo(states, { stroke: "#fff", strokeWidth: 0.5 })
],
color: {
scheme: "Spectral",
unknown: "#ddd",
type: "linear",
label: "% of county population with home broadband",
legend: true,
percent: true,
domain: [0, 100]
}
})
)