Public
Edited
Dec 20, 2022
Insert cell
Insert cell
Insert cell
states.csv
Type Table, then Shift-Enter. Ctrl-space for more options.

Insert cell
import {aq, op} from "@uwdata/arquero"

Insert cell
Insert cell
myTable = aq.from(states)
Insert cell
myTable
.view()
Insert cell
Insert cell
Insert cell
viewof myFilteringValue = Inputs.select(dropdown_choices, {multiple: true, label: "Select Region: "})
Insert cell
myFilteredTable = myTable
.params({ myFilteringValue })
// .filter((d) => myFilteringValue !== "All" ? d.Region.includes(myFilteringValue) : true)
.filter(aq.escape((d) => ( myFilteringValue[0] !== "All" && myFilteringValue.length !== 0) ? myFilteringValue.includes(d.Region) : true) )
.view()
Insert cell
myFilteringValue.length
Insert cell
myFilteringValue[0]
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