The Generalised Kernel Covariance Measure

Luca Bergen, Dino Sejdinovic, Vanessa Didelez

TL;DR

This paper introduces the Generalised Kernel Covariance Measure (GKCM), a new kernel-based method for testing conditional independence (CI). GKCM is more flexible than existing methods because it can use a wider range of regression models, leading to better calibration and performance, especially when paired with tree-based regression.

What Problem Does This Paper Address?

Conditional independence (CI) is a fundamental concept in statistics and causal inference, crucial for tasks like causal discovery. Testing for CI involves determining if two random variables are independent given a third set of variables. Existing kernel-based CI tests often rely on kernel ridge regression (KRR), which can be computationally expensive to tune and may produce poorly calibrated results if not tuned properly. This limits their practical usefulness and reliability. The paper aims to develop a kernel-based CI test that is less sensitive to hyperparameter tuning and can leverage more robust regression techniques.

Methods

The core contribution is the Generalised Kernel Covariance Measure (GKCM). GKCM builds upon the idea of embedding variables into Reproducing Kernel Hilbert Spaces (RKHSs) to capture complex, non-linear relationships. Unlike previous kernel-based CI tests that exclusively use kernel ridge regression (KRR) for estimating conditional expectations, GKCM is regression-model-agnostic. This means it can be used with a broader class of regression estimators, including more robust methods like random forests.

The GKCM framework is based on the Generalised Hilbertian Covariance Measure (GHCM). It targets the mean conditional covariance of the embedded variables. The paper also establishes theoretical conditions under which GKCM achieves uniform asymptotic level guarantees, a desirable property for statistical tests.

Datasets

Not discussed in the paper. The paper focuses on theoretical development and simulation studies using synthetic data.

Key Insights and Ideas

  • Regression Model Flexibility is Key: The paper highlights that the choice of regression model is critical for the performance of kernel-based CI tests. Relying solely on KRR, with its tuning challenges, is a significant bottleneck.
  • Random Forests as a Strong Alternative: Pairing GKCM with random forests (specifically, Distributional Random Forests) yields excellent results, often outperforming state-of-the-art methods in terms of both type I error control and power. This suggests that more robust, less hyperparameter-sensitive models can be highly effective.
  • Uniform Asymptotic Level Guarantees: By building on the GHCM framework, GKCM can achieve theoretical guarantees on its type I error rate, which is crucial for reliable statistical inference.
  • Mean-Zero vs. Almost-Sure-Zero Tests: The paper distinguishes between tests that target the expectation of conditional covariances (mean-zero) and those that target the almost-sure conditional covariances (a.s.-zero). GKCM is a mean-zero test, which can be more robust in certain scenarios.

Key Results

The simulation study demonstrates that GKCM, particularly when paired with random forests (GKCM RF), frequently outperforms existing state-of-the-art CI tests.

  • Type I Error Control: In null settings, GKCM RF consistently achieves approximately nominal type-I error rates, often outperforming other methods that show inflated error rates. This is especially true in challenging null scenarios.
  • Power: In alternative settings, GKCM RF shows competitive or superior power compared to other kernel-based tests. While it might have slightly below-average power in some specific linear settings, it excels in non-linear scenarios.
  • Robustness to Hyperparameters: The paper suggests that GKCM with random forests performs well even without extensive hyperparameter tuning, a significant advantage over KRR-based methods.

Limitations and Future Work

  • Hyperparameter Tuning: While GKCM is designed to be less sensitive to hyperparameters than KRR-based methods, the paper acknowledges that further investigation into computationally feasible hyperparameter tuning strategies could potentially improve performance further.
  • Mixed Data Types: The current study focuses on continuous data. An extension to settings with mixed data types is suggested as a future direction.
  • Theoretical Guarantees: While sufficient conditions for uniform asymptotic type-I error guarantees are provided, establishing specific examples of distribution families for which these conditions hold is an open research question.
  • Systematic Evaluation of Regression Methods: The paper suggests a systematic evaluation of other regression methods beyond random forests and KRR.

Summary updated

Abstract

We consider the problem of conditional independence (CI) testing and adopt a kernel-based approach. Kernel-based CI tests embed variables in reproducing kernel Hilbert spaces, regress their embeddings on the conditioning variables, and test the resulting residuals for marginal independence. This approach yields tests that are sensitive to a broad range of conditional dependencies. Existing methods, however, rely heavily on kernel ridge regression, which is computationally expensive when properly tuned and yields poorly calibrated tests when left untuned, which limits their practical usefulness. We propose the Generalised Kernel Covariance Measure (GKCM), a regression-model-agnostic kernel-based CI test that accommodates a broad class of regression estimators. Building on the Generalised Hilbertian Covariance Measure framework (Lundborg et al., 2022), we characterise conditions under which GKCM satisfies uniform asymptotic level guarantees. In simulations, GKCM paired with tree-based regression models frequently outperforms state-of-the-art CI tests across a diverse range of data-generating processes, achieving better type I error control and competitive or superior power.
BibTeX
@inproceedings{bergen2026generalised,
  author = {Luca Bergen and Dino Sejdinovic and Vanessa Didelez},
  title = {{The Generalised Kernel Covariance Measure}},
  booktitle = {CLeaR},
  year = {2026},
  url = {https://openreview.net/forum?id=TbQacuWeQH},
}
Figure