Published
Edited
Sep 7, 2021
1 fork
3 stars
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Plot.plot({
y: {
grid: true
},
marks: [
Plot.line(data, {x: "Start time", y: "cals"}),
Plot.line(data, {x: "Start time", y: "walking"})
]
})
Insert cell
Insert cell
Plot.plot({
height: 400,
width: 1100,
x: {
label: "Time",
domain: [new Date("2015-01-01"), new Date("2021-09-01")],
transform: f => new Date(f)
},
y: {
label: "Cals expended",
grid: true,
ticks: 5,
domain: [0, 5000],
},
marks: [
Plot.line(data, {x: "Start time", y: "cals"}),
Plot.line(data, {x: "Start time", y: "walking", stroke: "red", opacity: 0.5})
]
})
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Type JavaScript, then Shift-Enter. Ctrl-space for more options. Arrow ↑/↓ to switch modes.

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