Public
Edited
Feb 16, 2023
Fork of House prices
Insert cell
Insert cell
workbook = FileAttachment("ceny_mieszkan.xlsx").xlsx()
Insert cell
wtorny = workbook.sheet("Rynek pierwotny", {headers: true})

Insert cell
//wtornyCleaned = wtorny[0].Year.toLocaleString(undefined, {useGrouping: false})
Insert cell
//console.log(wtorny[0].city)
Insert cell
wtorny
Type Table, then Shift-Enter. Ctrl-space for more options.

Insert cell
viewof k = Inputs.range([1, 20], {label: "Smoothing", step: 1})
Insert cell
Plot.plot({
x: {
tickFormat: ""
},
marks: [
Plot.line(wtorny, {x: "Year", y: "medianPrice", k: k, reduce: "mean", stroke: "city"}),
Plot.dot(wtorny, {x: "Year", y: "medianPrice", fill: "city"})
],
inset: 8,
grid: true,
color: {
legend: true,
},
// color: {
// domain: ["Katowice", "Opole"],
// legend: true
// },
marginLeft: 50,
marginBottom: 50
})
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