Visualizing stability: a sensitivity analysis framework for t-SNE embeddings

Susanne Zabel, Philipp Hennig, Kay NieseltFrontiers in Bioinformatics 2026

Abstract

t-distributed Stochastic Neighbour Embedding (t-SNE) is a cornerstone for visualizing high-dimensional biological data, where each high-dimensional data point is represented as a point in a two-dimensional map. However, this static map provides no information about the stability of the visual layout, the features that influence it, or the impact of uncertainty in the input data. This work introduces a computational framework that allows one to extend the standard t-SNE plot by visual clues about the stability of the t-SNE embedding. First, we perform a sensitivity analysis to determine feature influence: by combining the Implicit Function Theorem with automatic differentiation, our method computes the sensitivity of the embedding w.r.t. the input data, provided in a Jacobian of first-order derivatives. Heatmap-visualizations of this Jacobian or summarizations thereof reveal which input features are most influential in shaping the embedding and identifying regions of structural instability. Second, when input data uncertainty is available, our framework uses this Jacobian to propagate error, probabilistically quantifying the positional uncertainty of each embedded point. This uncertainty is visualized by augmenting the plot with hypothetical outcomes, which display the positional confidence of each point. We apply our framework to three diverse biological datasets (bulk RNA-seq, proteomics, and single-cell transcriptomics), demonstrating its ability to directly link visual patterns to their underlying biological drivers and reveal ambiguities invisible in a standard plot. By providing this principled means to assess the robustness and interpretability of t-SNE visualizations, our work enables more rigorous and informed scientific conclusions in bioinformatics.

Introduction

t-Distributed Stochastic Neighbor Embedding (t-SNE) has become the "gold standard" for visualizing high-dimensional biological data, such as single-cell RNA sequencing. By squashing thousands of gene expressions into a 2D plot, it allows researchers to identify clusters of similar cells. However, t-SNE operates largely as a "black box." Standard plots provide no information about why specific points are placed where they are, which features drive those placements, or how stable the layout is in the face of measurement noise. Without a way to assess sensitivity and uncertainty, researchers risk over-interpreting visual patterns that may be structurally fragile.

Methodology: The Implicit Function Theorem Approach

To address these limitations, we introduce a computational framework that moves beyond static point plotting. The core innovation lies in applying the Implicit Function Theorem (IFT) combined with automatic differentiation (via the JAX library) to the converged t-SNE solution.

Overview of the sensitivity analysis framework, showing the derivation of feature importance, sample sensitivity, and embedding uncertainty from the Jacobian of sensitivities.

1. Sensitivity Jacobian

Rather than differentiating through the entire iterative optimization process, our method analyzes the final converged state. By applying the IFT to the optimality conditions, we calculate a "Jacobian" matrix. This matrix quantifies the relationship between every input feature and every output coordinate in the 2D embedding.

2. Handling Rotational Invariance

t-SNE is invariant to global rotation and translation, which mathematically results in a singular Hessian matrix. We resolve this by employing the Moore-Penrose pseudoinverse, allowing us to ignore meaningless global shifts and focus on meaningful structural changes within the data.

3. Error Propagation and Visualization

If input data uncertainty is known (e.g., variance across biological replicates), the framework uses the Jacobian to propagate this error into the embedding space. This results in several intuitive visual tools:

  • Feature Influence Heatmaps: Identifying specific genes that drive cluster formation.
  • Sample Sensitivity Scores: Highlighting "fragile" points whose positions are highly sensitive to small perturbations.
  • Hypothetical Outcome Plots: Visualizing positional confidence through animated or overlaid plots that show the "wiggle room" of each point.

Experimental Validation

The framework was validated on diverse biological datasets, including bulk RNA-seq, proteomics, and single-cell transcriptomics.

Linking Visuals to Biology

In a time-series study of Streptomyces coelicolor, sensitivity analysis directly linked the separation of late-stage timepoints to the actinorhodin biosynthetic gene cluster. This finding was consistent across both transcriptomic and proteomic data, demonstrating the framework's robustness across different "omics" layers.

Identifying Structural Fragility

In single-cell RNA-seq data (PBMCs), the most sensitive regions were found at the interfaces between similar cell types, such as CD4 and CD8 T cells. Interestingly, the analysis revealed that cells within dense cluster cores can sometimes be more sensitive than those on the periphery, challenging the common assumption that tight clusters are inherently more robust.

Discussion and Limitations

While the framework provides a principled means to assess t-SNE interpretability, some challenges remain. The primary computational bottleneck is the $O(N^3)$ scaling relative to the number of samples ($N$) due to the Hessian pseudoinversion. While practical for thousands of points, further optimization via iterative solvers is needed for million-cell atlases. Additionally, this method focuses on local stability of a single solution rather than the global stability across different random initializations. Future work will explore extending this IFT-based approach to other differentiable embedding methods like UMAP.

Conclusion

By providing visual clues about stability and feature influence, this framework enables more rigorous and informed scientific conclusions. It transforms t-SNE from a purely qualitative visualization tool into a quantitative diagnostic framework for high-dimensional biological discovery.

Summary updated

BibTeX
@inproceedings{zabel2026visualizing,
  author = {Susanne Zabel and Philipp Hennig and Kay Nieselt},
  title = {{Visualizing stability: a sensitivity analysis framework for t-SNE embeddings}},
  booktitle = {Frontiers in Bioinformatics},
  year = {2026},
  doi = {10.3389/fbinf.2025.1719516},
}
Figure