A Probabilistic Grammar of Graphics
Xiaoying Pu, Matthew Kay
Abstract
Visualizations depicting probabilities and uncertainty are used everywhere from medical risk communication to machine learning, yet these probabilistic visualizations are difficult to specify, prone to error, and their designs are cumbersome to explore. We propose a Probabilistic Grammar of Graphics (PGoG), an extension to Wilkinson's original framework. Inspired by the success of probabilistic programming languages, PGoG makes probability expressions, such as P(A|B), a first-class citizen in the language. PGoG abstractions also reflect the distinction between probability and frequency framing, a concept from the uncertainty communication literature. It is expressive, encompassing product plots, density plots, icon arrays, and dotplots, among other visualizations. Its coherent syntax ensures correctness (that the proportions of visual elements and their spatial placement reflect the underlying probability distribution) and reduces edit distance between probabilistic visualization specifications, potentially supporting more design exploration. We provide a proof-of-concept implementation of PGoG in R.
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Your agent calls
Luneget_paper_fulltext
Free to start. No credit card required.
Terminal
Install the CLIlune papers fulltext 2e8ce841-2ec7-4ff5-af08-57bfae3bcc9dCited by top-tier papers8
- Integrated Visualization Editing via Parameterized Declarative TemplatesAndrew M. McNutt, Ravi ChughCHI 2021 · 39 citations
- No Grammar to Rule Them All: A Survey of JSON-style DSLs for VisualizationAndrew M. McNuttIEEE VIS 2022 · 37 citations
- Investigating Perceptual Biases in Icon ArraysCindy Xiong, Ali Sarvghad, Daniel G. Goldstein, Jake M. Hofman et al.CHI 2022 · 35 citations
- How Data Analysts Use a Visualization Grammar in PracticeXiaoying Pu, Matthew KayCHI 2023 · 10 citations
- ComputableViz: Mathematical Operators as a Formalism for Visualisation Processing and AnalysisAoyu Wu, Wai Tong, Haotian Li, Dominik Moritz et al.CHI 2022 · 8 citations
Related papers
- ggdist: Visualizations of Distributions and Uncertainty in the Grammar of GraphicsMatthew KayIEEE VIS 2023 · 112 citations
- GoFish: A Grammar of More Graphics!Josh Pollock, Arvind SatyanarayanIEEE VIS 2025 · 2 citations
- Higher Order Bayesian Networks, ExactlyClaudia Faggian, Daniele Pautasso, Gabriele VanoniPOPL 2024 · 4 citations
- Graphical Perception of Icon Arrays versus Bar Charts for Value Comparisons in Health Risk CommunicationJade Kandel, Jiayi Liu, Arran Zeyu Wang, Chin Tseng et al.IEEE VIS 2025 · 3 citations
- Differentially Private Bayesian ProgrammingGilles Barthe, Gian Pietro Farina, Marco Gaboardi, Emilio Jesús Gallego Arias et al.CCS 2016 · 28 citations
