Public
Edited
Apr 1
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
xAccessor = (d) => d.year
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
leuTheme = theme
Insert cell
leuFonts = fonts
Insert cell
leuElements = {
importLeuFromCDN("leu-dropdown.js", leuVersion);
importLeuFromCDN("leu-menu.js", leuVersion);
importLeuFromCDN("leu-menu-item.js", leuVersion);
importLeuFromCDN("leu-icon.js", leuVersion);
}
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
contentId = DOM.uid("zhstat-content")
Insert cell
Insert cell
colors = ({
Variable: {
"Biogener Anteil im verbrannten Abfall": ZHColors.chart.grassgreen
}
})
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
fetchedData = d3.csv(dataPath, (d) => ({
...d,
Wert: Number.parseFloat(d.Wert),
Jahr: +d.Jahr
}))
Insert cell
Insert cell
titel = {
const titel = [...new Set(fetchedData.map((d) => d.Indikator_Name))];
const gebiet = [...new Set(fetchedData.map((d) => d.Gebiet))];

return `${titel}, ${gebiet}`;
}
Insert cell
untertitel = `In ${unit}`
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
import {
colors as ZHColors,
fonts as ZHFonts
} from "@statistikzh/common-styles"
Insert cell
import { createPNG } from "@statistikzh/shared-imports"
Insert cell
import {
fonts,
theme,
importLeuFromCDN
} with { leuVersion as version } from "@statistikzh/leu-general"
Insert cell
leuVersion = "^0.9"
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