Layering, faceting and coordinated views: compose charts for comparison
Use layers for marks in one frame, facets for repeated subsets, and coordinated views when separate charts need linked selection.
Choose a chart composition by the comparison task. Use a layer when a few series share the same axes and readers need to compare them directly; in Vega-Lite, multiple view specifications go in a layer, with scales, axes, and legends shared by default. Use facets or small multiples when the same measure should be repeated for separate groups. Keep comparable scales when cross-group magnitude matters. Use coordinated views when related questions need separate charts linked by selection. State what a selection changes, how selections combine across panels, and how to clear them. Vega-Lite supports point selections for discrete values and interval selections for ranges; behavior can differ in a host application.
Hypothetical example: for monthly orders in three regions, overlay three lines if they remain readable; use small multiples with a common vertical scale if lines overlap; link a region selection to a product-mix chart when readers need that detail. This example is illustrative, not tested evidence.
Before sharing, check data grain, filters, aggregation, axis scales, and legends. Test selection, clearing, and empty results. Sources: Vega-Lite layering, faceting, and selection parameters.