Exploring Data
Sunday, 20 July 2025
Data from the Bureau of Labor Statistics from Observable.
Filter data to show only Michigan division.
Plot.plot({
x: {
// // insetLeft: 10,
// padding: 0.5,
// range: [30, 300],
// align: 1,
},
y: {
grid: true,
label: "Unemployment (%)"
},
marginLeft: 0,
marginRight: 0,
color: {
domain: [false, true],
range: ["#ccc", "red"]
},
marks: [
// Plot.ruleY([0]),
Plot.line(bls, {
x: "date",
y: "unemployment",
z: "division",
transform: (data, facets) => ({
data,
facets: facets.map((facet) => {
return facet.filter((i) => {
return /, MI /.test(data[i].division);
});
})
})
})
]
})