Public
Edited
Aug 2, 2023
2 stars
Insert cell
Insert cell
Plot.plot({
color: { legend: true },
marks: [
Plot.lineY(data, {
x: "day",
y: "temperature",
stroke: "year",
group: "year"
})
]
})
Insert cell
data = {
const ds = [];
for (const { name, data } of raw_data) {
for (let i = 0; i < data.length; i++) {
ds.push({
year: +name,
day: new Date(1980, null, i),
date: new Date(+name, null, i),
temperature: data[i]
});
}
}
return ds.filter((d) => d.temperature !== null);
}
Insert cell
raw_data = d3.json(
"https://climatereanalyzer.org/clim/sst_daily/json/oisst2.1_natlan1_sst_day.json"
)
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