Probabilistic Contrastive Principal Component Analysis

Didong Li, Andrew Jones, Barbara E. EngelhardtarXiv 2020

Abstract

Principal Component Analysis (PCA) is a cornerstone of dimensionality reduction, yet it struggles to isolate signals unique to a specific "foreground" dataset when compared to a "background" control. While Contrastive PCA (CPCA) was developed to address this, its lack of a probabilistic foundation leads to challenges in hyperparameter tuning, uncertainty quantification, and handling missing data. We introduce Probabilistic Contrastive PCA (PCPCA), a generative model that optimizes a relative likelihood objective. PCPCA provides a robust, unified framework that generalizes existing methods while enabling synthetic data generation and principled statistical inference.

Introduction

In many scientific domains, researchers seek to identify patterns present in a target dataset (the foreground) that are absent or diminished in a control dataset (the background). For instance, identifying gene expression patterns unique to diseased patients compared to healthy individuals. Standard PCA identifies directions of maximum variance across the entire data, often conflating shared background noise with the signal of interest.

Contrastive PCA (CPCA) was designed to find variance enriched specifically in the foreground. However, as a purely algebraic method, CPCA suffers from several limitations: the tuning parameter $\gamma$ is difficult to optimize, it cannot quantify uncertainty, it is sensitive to missing data, and it lacks generative capabilities. PCPCA addresses these gaps by framing contrastive dimensionality reduction within a probabilistic, generative context.

Methods: Probabilistic Contrastive PCA

PCPCA assumes that data is generated from a latent low-dimensional space with additive Gaussian noise. The core innovation is the use of a relative likelihood objective function. Rather than maximizing the likelihood of the foreground data alone, PCPCA maximizes the ratio of the foreground likelihood to the background likelihood, scaled by a hyperparameter $\gamma$:

$$L_{rel} = \frac{p(X_{fg} | \theta)}{p(X_{bg} | \theta)^\gamma}$$

This objective forces the model to explain the foreground data while actively minimizing its explanation of the background data. The authors derive a Maximum Relative Likelihood Estimate (MRLE) and utilize Gibbs posteriors to enable Bayesian inference in this non-standard likelihood setting. Furthermore, a reparameterization of $\gamma$ based on sample size ratios ensures the parameter remains within a stable, interpretable range (typically $[0, 1]$), making it vastly easier to tune.

A Unified Framework

One of the most significant theoretical contributions of PCPCA is its role as a "Grand Unified Theory" for this class of dimensionality reduction techniques. By adjusting the noise variance ($\sigma^2$) and the contrastive parameter ($\gamma$), PCPCA reduces to several well-known methods.

The relationship between PCPCA and related dimensionality reduction methods.

As illustrated above, setting $\gamma = 0$ reduces PCPCA to Probabilistic PCA (PPCA). If the noise variance $\sigma^2$ is taken to the limit of zero, PCPCA recovers standard CPCA. When both conditions are met, the model simplifies to classical PCA.

Experimental Results

The authors validated PCPCA across several diverse datasets, including single-cell RNA sequencing, mouse protein expression, and corrupted MNIST digits.

  • Robustness and Imputation: PCPCA demonstrated superior resilience to noise compared to CPCA. In experiments with missing data, PCPCA maintained high log-likelihoods and achieved lower imputation error than PPCA, whereas standard CPCA could not function with missing values.
  • Tuning and Interpretability: Unlike the erratic tuning curves often seen in CPCA, PCPCA’s reparameterized $\gamma$ produced monotonic and predictable performance improvements, significantly simplifying model selection.
  • Generative Performance: As a generative model, PCPCA can isolate and "hallucinate" foreground signals. When trained on MNIST digits superimposed on complex background images, the model successfully generated clean reconstructions of the digits, effectively subtracting the background interference.

Conclusion

PCPCA bridges the gap between contrastive and probabilistic dimensionality reduction. By providing a formal model-based approach, it resolves the practical limitations of CPCA while offering new capabilities like uncertainty quantification and data imputation. Future research may explore extending this framework to non-Gaussian data distributions and non-linear kernelized variants.

Summary updated

BibTeX
@misc{li2020probabilistic,
  author = {Didong Li and Andrew Jones and Barbara E. Engelhardt},
  title = {{Probabilistic Contrastive Principal Component Analysis}},
  year = {2020},
  eprint = {2012.07977},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2012.07977},
}
Figure