Abstract
We present a grammar for expressing hypotheses in visual data analysis to formalize the previously abstract notion of "analysis tasks." Through the lens of our grammar, we lay the groundwork for how a user's data analysis questions can be operationalized and automated as a set of hypotheses (a hypothesis space). We demonstrate that our grammar-based approach for analysis tasks can provide a systematic method towards unifying three disparate spaces in visualization research: the hypotheses a dataset can express (a data hypothesis space), the hypotheses a user would like to refine or verify through analysis (an analysis hypothesis space), and the hypotheses a visualization design is capable of supporting (a visualization hypothesis space). We illustrate how the formalization of these three spaces can inform future research in visualization evaluation, knowledge elicitation, analytic provenance, and visualization recommendation by using a shared language for hypotheses. Finally, we compare our proposed grammar-based approach with existing visual analysis models and discuss the potential of a new hypothesis-driven theory of visual analytics.
Introduction: Beyond Abstract Tasks
In the field of visual analytics, the concept of a "task"—such as finding outliers, comparing values, or characterizing distributions—is central to design and evaluation. However, these terms remain abstract and difficult to operationalize for automated systems. A developer building a recommendation engine or an automated tool struggles to "code" for a task as broad as "find anomalies."
This paper addresses the disconnect between three critical areas: the user's intent, the data's capabilities, and the visualization's affordances. By replacing vague task descriptions with a formal Grammar of Hypotheses, we can precisely determine if a visualization bridges the gap between a user's curiosity and the data's reality.
The Grammar of Hypotheses
The proposed grammar provides a formal syntax (inspired by SQL and PEG notation) that defines a hypothesis as a "qualifiable relation between at least two variables." The core structure follows the pattern: hyp :- expr op expr [pred].
- Expressions (
expr): These can be constants, data attributes, or functions (such asAVG,SUM, orCORR). - Operators (
op): Binary relations like>,<, or=. - Predicates (
pred): Filters similar to a SQLWHEREclause (e.g.,[year > 2020]).
This formalization allows high-level analytical questions to be decomposed into machine-readable strings that can be evaluated against a dataset.
Mapping the Hypothesis Spaces
The breakthrough of this framework is the mapping of all components of visual analysis into three distinct "Hypothesis Spaces":
- Data Hypothesis Space ($H_D$): The set of all hypotheses that can be evaluated using the available dataset.
- Analysis Hypothesis Space ($H_A$): The set of hypotheses a user is interested in, which may include variables or relationships not currently present in the data.
- Visualization Hypothesis Space ($H_V$): The set of hypotheses a specific chart design (e.g., a bar chart with specific encodings) is capable of proving or disproving.
Formalizing Visualization Quality
By using this grammar, "success" in visual analytics is mathematically defined as the non-null intersection of these three spaces ($H_D \cap H_V \cap H_A$). Conversely, the grammar allows us to define specific failure modes:
- Inappropriate Visualization: A scenario where the chart's capabilities ($H_V$) do not overlap with the data's capabilities ($H_D$).
- Ineffective Visualization: A scenario where the chart ($H_V$) does not overlap with the user's interests ($H_A$).
- Insufficient Data: A scenario where the user's questions ($H_A$) fall outside what the data ($H_D$) can support.
This framework views the process of data analysis as "space shrinking," where a user iteratively adds constraints to their grammar to narrow their analysis space until it reaches a single, testable hypothesis.
Case Study: VAST 2017 Challenge
The utility of the grammar was demonstrated using the VAST 2017 Challenge (Mini-Challenge 1) dataset, which involves sensor logs of vehicle movements in a nature reserve. The authors successfully mapped six complex analytical questions into the grammar. This exercise revealed that the grammar could explicitly identify data gaps and provide precise definitions for tasks like "Find Anomalies" by requiring exact statistical thresholds (e.g., "value > 3 standard deviations from the mean"). Furthermore, it showed how a recommendation system could rank visualizations by calculating which chart type ($H_V$) has the largest overlap with the user's specific goals ($H_A$).
Conclusion and Future Directions
The Grammar of Hypotheses advocates for a shift from purely Exploratory Data Analysis (EDA) to Hypothesis-Driven Analysis (HDA). While currently limited to relational, tabular data and static visualizations, future work aims to account for perceptual limits (graphical perception constraints) and integrate with Natural Language Interfaces (NLIs). This would allow users to ask questions in plain English, which the system could then translate into formal hypotheses to verify against the data's capabilities automatically.
Summary updated