Public
Edited
Sep 24, 2023
Insert cell
Insert cell
MTA_Daily_Ridership_Data__Beginning_2020-9.csv
Type Table, then Shift-Enter. Ctrl-space for more options.

Insert cell
mta
X
Date
Y
Subways: Total Estimated Ridership
Color
Size
Facet X
Facet Y
Mark
Auto
Type Chart, then Shift-Enter. Ctrl-space for more options.

Insert cell
myValue = {
const a = 10;
const b = 20;

return a + b;
}

Insert cell
myValue * 20

Insert cell
myOtherValue = 200 + myValue
Insert cell
mta
SELECT * FROM mta
Insert cell
myNewDatabase = DuckDBClient.of({mta})
Insert cell
myEndpointData = d3.json("https://data.ny.gov/resource/vxuj-8kew.json")
Insert cell
Insert cell
mta
X
Date
Y
Subways: Total Estimated Ridership
Color
Date
Size
Facet X
Facet Y
Mark
dot
Type Chart, then Shift-Enter. Ctrl-space for more options.

Insert cell
pizza
Type Table, then Shift-Enter. Ctrl-space for more options.

Insert cell
viewof selectCategory = Inputs.select(["Classic", "Specialty","Vegetarian"], {label: "Select one"})
Insert cell
MyPizzaData
SELECT * FROM "MyPizzaData" WHERE category = ${selectCategory}
Insert cell
Plot.plot({
marks: [
Plot.rectY(myFilteredData, {
x: "order_date",
y: "orders",
interval: d3.utcDay}),
Plot.ruleY([0])
]
})
Insert cell
MyPizzaData
X
order_date
Y
sum
orders
Color
Size
Facet X
category
Facet Y
day_of_week
Mark
Auto
Type Chart, then Shift-Enter. Ctrl-space for more options.

Insert cell
Plot.plot({
marginLeft: 100,
marginRight: 200,
marks: [
Plot.frame({ strokeOpacity: 0.1 }),
Plot.rectY(
MyPizzaData,
Plot.binX(
{ y: "sum" },
{
fx: "category",
fy: "day_of_week",
x: "order_date",
y: "orders",
fill: "category",
tip: true
}
)
),
Plot.ruleY([0])
]
})
Insert cell
myChart = Plot.plot({
marks: [
Plot.areaY(aapl, {x: "Date", y: "Close"}),
Plot.ruleY([0])
]
})
Insert cell
import {data} from "@pstuffa/density-contour-matrix-with-brushing"
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