fill:"sum"// Change this to stroke when you fix the color, so you bin on the stroke channel
},
{
x:"order_date",
interval:d3.utcWeek
}
)
),
Plot.frame({stroke:"#aaa",strokeWidth:0.5})
]
})
Plot.plot({
width:720,
height:420,
facet:{
data:pizza,
y:"pizza_name",
x:"size",
marginRight:90,
label:""
},
marks:[
Plot.areaY(
pizza,
Plot.binX(
{y:"sum"},
{
x:"order_date",
y:"orders",
interval:d3.utcWeek,
tip:true
}
)
),
Plot.ruleY([0])
],
y:{
tickFormat:(d)=>""
}
})
pizza
Type Table, then Shift-Enter. Ctrl-space for more options.
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.