Public
Edited
Aug 28, 2024
1 star
Insert cell
Insert cell
Insert cell
data = {
let data_orig = await FileAttachment("penguins.csv").csv({ typed: true });
return data_orig
.filter((d) => !isNaN(d.body_mass_g))
.map((d) => {
d.body_mass_g_bigint = BigInt(d.body_mass_g);
return d;
});
}
Insert cell
Insert cell
Plot.plot({
marks: [
Plot.dot(
data,
Plot.normalizeY({
x: "flipper_length_mm",
y: "body_mass_g",
z: "island",
basis: "mean"
})
)
]
})
Insert cell
Insert cell
Plot.plot({
marks: [
Plot.dot(
data,
Plot.normalizeY({
x: "flipper_length_mm",
y: "body_mass_g_bigint",
z: "island",
basis: "mean"
})
)
]
})
Insert cell
Plot = require(await FileAttachment("plot.umd.min.js").url())
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