NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Detecting and Identifying Selection Structure in Sequential Data

Yujia Zheng, Zeyu Tang, Yiwen Qiu, Bernhard Schölkopf, Kun Zhang

Abstract

Selection bias is traditionally treated as a nuisance to be corrected. However, this research argues that selection is a fundamental component of the data-generating process. We prove that "selection structures"—where data is included based on hidden criteria—can be mathematically distinguished from direct causation or hidden confounding in sequential data. We provide a provably correct $O(N^2)$ algorithm to map these relationships using only observational data, demonstrating its efficacy on synthetic data and real-world musical compositions.

Introduction: The Hidden Role of Selection

In causal discovery, researchers typically focus on two primary relationships: direct causes ($X \to Y$) and latent confounders ($X \leftarrow C \to Y$). This paper highlights a third, often overlooked player: selection. Selection occurs when data points are included in a dataset based on a latent objective or criterion ($X \to S \leftarrow Y$). Because observations are only available when the selection variable $S$ is "active," it creates a statistical dependency between $X$ and $Y$ that can be easily mistaken for a causal link.

Conceptual illustration of selection bias where latent criteria (S) create statistical dependencies between observed variables.

In sequential data, such as music or financial time series, ignoring selection leads to an "overcomplicated inductive bias." For instance, a composer might choose notes $X_1$ and $X_5$ to fit a specific artistic theme ($S$). If $S$ is ignored, one might incorrectly infer a direct causal chain where $X_1$ causes $X_2$, which causes $X_3$, and so on. This framework identifies when dependencies arise from selection rather than direct physical or temporal causes.

Methods: Identifying Selection Structures

The authors establish the nonparametric identifiability of selection structures, proving that selection pairs can be uniquely distinguished from direct relations and confounded pairs without knowing the specific functional form of the data.

Distinguishing between (a) selection structures with latent collider $S_I$ and (b) confounded structures with latent common cause $C_I$.

The proposed three-stage constraint-based algorithm operates as follows:

  1. Stage One: Identifies all potential dependent pairs using conditional independence (CI) tests.
  2. Stage Two: Distinguishes between selection pairs and direct causal relations. Selection variables act as latent colliders; by conditioning on specific variables, the algorithm detects the unique "footprint" left by selection.
  3. Stage Three: Handles cases where latent confounders coexist with selection, removing spurious edges misidentified in earlier stages.

By leveraging the sequential nature of the data—specifically the principle that the future cannot cause the past—the algorithm achieves $O(N^2)$ complexity, a significant improvement over standard algorithms like PC or FCI which can reach exponential complexity.

Experimental Validation

Datasets

  • Synthetic Data: The algorithm was tested using linear Gaussian Structural Causal Models (SCMs) to evaluate precision and recall across 8 to 20 variables, with scalability tests reaching 1,000 variables.
  • Real-World Music:
    • Guitar soundtracks from Hotel California (Eagles): Analyzed to identify causal and selection structures in solo motifs.
  • String section from Panis Angelicus (César Franck): Validated against known musical themes and lyrical structures.
  • Processing: Audio nodes represented individual musical bars, converted to frequency domain features via FFT and Mel scale conversion.

Key Results

  • High Precision: On synthetic data, the algorithm significantly outperformed baseline models that ignored selection-specific structural conditions.
  • Scalability: The algorithm processed a graph with 600 variables in approximately one hour on a standard CPU.
  • Musical Logic: In Hotel California, the identified selection pairs aligned with the "Andalusian cadence." In Panis Angelicus, the structures matched the religious themes of the lyrics, suggesting the algorithm can capture "artistic intent."

Discussion and Future Work

A key insight of this work is viewing selection as information. Rather than a bias to be mitigated, selection is a "veridical inductive bias" that provides insight into the generative process, such as a composer's intent. The "arrow of time" provides a powerful constraint that simplifies causal discovery in sequential domains.

However, limitations remain. The proofs rely on specific structural conditions (e.g., the presence of "blocking" nodes). If the causal graph is too sparse, some structures may remain unidentifiable. While currently optimized for sequential data, future work could integrate these selection structures into large-scale foundation models (like LLMs) to improve robustness and interpretability.

Summary updated

BibTeX
@inproceedings{zheng2024detecting,
  author = {Yujia Zheng and Zeyu Tang and Yiwen Qiu and Bernhard Schölkopf and Kun Zhang},
  title = {{Detecting and Identifying Selection Structure in Sequential Data}},
  booktitle = {International Conference on Machine Learning},
  year = {2024},
  url = {https://openreview.net/forum?id=5PQhu8flSO},
}
Figure