Public
Edited
May 28, 2023
Insert cell
Insert cell
Insert cell
Insert cell
data = FileAttachment("players_20.csv").csv()
Insert cell
nationality_count = d3.rollup(
data,
(v) => d3.count(v, (d) => d.sofifa_id),
(d) => d.nationality
)
Insert cell
Insert cell
dataset = FileAttachment("players_20.csv").csv()
Insert cell
data_w4 = dataset.map((d) => ({
age: Number(d.age),
wage_eur: Number(d.wage_eur),
international_reputation: Number(d.international_reputation)
}))
Insert cell
Plot.plot({
marks: [
Plot.dot(data_w4, {
x: "age",
y: "wage_eur",
fill: "international_reputation"
})
],
color: { legend: true },
marginLeft: 100
})
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
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