Published
Edited
May 7, 2021
2 stars
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
import {DatasetteClient} from "@asg017/datasette-client"
Insert cell
db = DatasetteClient('https://covid-19.datasettes.com/covid')
Insert cell
Insert cell
import { Select, Table } from "@observablehq/inputs"
Insert cell
counties = db`select distinct county from latimes_county_totals;`
Insert cell
viewof county = Select(counties.map(d => d.county))
Insert cell
Insert cell
countyCases = db`select * from latimes_county_totals where county = ${county} order by date asc;`.then(
rows =>
rows.map(d => ({
...d,
date: new Date(d.date)
}))
)
Insert cell
Table(countyCases)
Insert cell
Insert cell
import { Plot } from "@observablehq/plot"
Insert cell
Plot.barY(countyCases, { x: "date", y: "new_confirmed_cases" }).plot()
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