Illustration of four researchers using computers and tablets to analyze data, with charts and scientific diagrams displayed on screens and in the background.

Single-Cell vs Spatial Omics: Data Structures, Workflows, and What Each Assay Lets You Discover

Table of Contents
Picture of Jonathan Alles

Jonathan Alles

EVOBYTE Digital Biology

By EVOBYTE Your partner in bioinformatics

Introduction

Ask three analysts to compare single‑cell RNA‑seq (scRNA‑seq) and spatial transcriptomics, and you’ll hear the same refrain: “they feel similar, until they don’t.” Both start from counts of transcripts and end with clusters, markers, and biological stories. Yet the data you manipulate, the questions you can ask, and even the definitions of a “cell” or a “marker gene” diverge quickly. If you’ve mastered scRNA‑seq pipelines and are eyeing spatial omics, this guide maps the differences you’ll meet in data structure, artifact handling, workflows, and biological readouts—and shows where the two technologies meet in the middle to answer questions neither can solve alone.

From barcodes to coordinates: how data structures diverge after preprocessing

With scRNA‑seq, your basic object is a sparse matrix of unique molecular identifier (UMI) counts with cells as rows (observations) and genes as columns (variables). After quality control, normalization, and feature selection, you analyze a “feature‑barcode matrix” that largely ignores where the cell came from in the tissue. The metadata describe cells; there is no native geometry.

Spatial assays add geometry and often imagery. After running the vendor pipeline, you usually obtain a counts table similar to scRNA‑seq plus per‑observation coordinates that place each measurement in tissue space. Sequencing‑based platforms such as Visium or Slide‑seq deliver spot‑level expression profiles, each with an (x, y) location and a linked histology image. Analysis toolkits represent this as an expression matrix plus a spatial coordinate array and an associated image object in the same container (for example, an AnnData or Seurat object with an image slot and a spatial coordinate field). The extra modalities—coordinates, scale factors, and image metadata—change how you subset, normalize, and visualize from the very first step.

Imaging‑based platforms (for example, in situ RNA chemistries) often ship two complementary artifacts: a “cell by gene” matrix from segmentation and a high‑granularity molecule table listing every decoded transcript with subcellular coordinates and quality metrics. You can work at the cell level, the molecule level, or bounce between them to study localization within membranes or nuclei. In other words, spatial omics expands your data model from “counts per cell” to “counts per spatial unit,” where the unit might be a spot, a segmented cell, or even a 2–8 μm bin.

Cells and doublets versus spots and segments: what your “unit of analysis” really is

In scRNA‑seq, each observation should be one cell, yet doublets—two cells sharing a droplet—are routine. They create hybrid profiles and can masquerade as transitional states. Doublet detection tools flag these artifacts by simulating or modeling synthetic mixtures and searching for “too‑close” neighbors in expression space. Removing doublets stabilizes clustering and marker calling and reduces false trajectories.

Spatial assays invert the problem. The observation may not be a single cell at all. In spot‑based sequencing platforms, a spot can capture transcripts from multiple neighboring cells. That mixture is a feature, not a bug, but it changes your expectations: a single observation may be a composition of cell types. Conversely, in imaging‑based assays with segmentation, each observation is intended to be a single cell, but segmentation itself can merge neighbors or split one cell into two; you inspect masks and molecule distributions to verify boundaries. Recognizing whether your “row” represents a pure cell, a mixture, or a bin is the first design decision that shapes the analysis that follows. For Visium in particular, the manufacturer notes that a spot typically captures transcripts from more than one cell, often multiple cells per spot, which motivates downstream deconvolution.

Analysis workflows in practice: scRNA‑seq pipelines next to spatial pipelines

The canonical scRNA‑seq pipeline is now familiar. You filter low‑quality cells and genes, normalize counts, pick highly variable genes (HVGs), compute principal components, build a k‑nearest‑neighbor graph, cluster (Leiden/Louvain), and map the result with UMAP or t‑SNE. You then test cluster markers to assign biological identities, and optionally model trajectories or differential expression across conditions.

Spatial workflows borrow the same backbone but add steps grounded in geometry and imaging. You still perform QC and normalization, but you also register spots or cells to a tissue image, filter by “in‑tissue” flags, and build a spatial graph that encodes adjacency in physical space. From there you can cluster in expression space, in spatial space, or both; detect spatially variable genes (SVGs) that form gradients or patterns across the tissue; quantify neighborhood enrichment among clusters; and infer cell–cell interactions conditioned on proximity. The combination of expression and location lets you ask whether a gene is not just variable, but spatially organized.

Here is a minimal, side‑by‑side taste of each pipeline.

Example: scRNA‑seq with Scanpy

import scanpy as sc

# Load and QC
adata = sc.read_h5ad("pbmc.h5ad")
sc.pp.filter_cells(adata, min_genes=200)
sc.pp.filter_genes(adata, min_cells=3)
adata.var['mt'] = adata.var_names.str.startswith('MT-')
sc.pp.calculate_qc_metrics(adata, qc_vars=['mt'], inplace=True)
adata = adata[adata.obs.pct_counts_mt < 10].copy()

# Normalize, HVGs, PCA, neighbors, clustering
sc.pp.normalize_total(adata, target_sum=1e4)
sc.pp.log1p(adata)
sc.pp.highly_variable_genes(adata, flavor="seurat_v3", n_top_genes=3000)
adata = adata[:, adata.var.highly_variable].copy()
sc.tl.pca(adata, svd_solver="arpack")
sc.pp.neighbors(adata, n_neighbors=20, n_pcs=50)
sc.tl.leiden(adata, resolution=0.5)
sc.tl.rank_genes_groups(adata, groupby="leiden", method="wilcoxon")

Example: spatial transcriptomics with Squidpy

import scanpy as sc, squidpy as sq

adata = sq.datasets.visium_hne_adata()  # example Visium dataset
# Preprocessing (similar to scRNA-seq)
sc.pp.normalize_total(adata, target_sum=1e4); sc.pp.log1p(adata)
# Build a spatial graph and compute spatial stats
sq.gr.spatial_neighbors(adata, coord_type="grid")           # adjacency in tissue space
sq.gr.spatial_autocorr(adata, mode="moran", n_perms=100)    # spatially variable genes
sq.gr.nhood_enrichment(adata, cluster_key="cluster")        # cluster–cluster proximity

That second block highlights spatial‑first steps: building a spatial neighbor graph and quantifying spatial autocorrelation and neighborhood enrichment. Moran’s I and Geary’s C serve as workhorse statistics to find genes whose expression is not random in space, while neighborhood enrichment quantifies which clusters co‑localize more than expected by chance.

Markers that matter: highly variable genes, cluster markers, and spatial markers

HVGs drive dimensionality reduction for both modalities, but “marker genes” fork into two notions. In scRNA‑seq, you typically mean cluster markers: genes that distinguish one molecularly defined group from others. Tests rank genes by differential expression between clusters or conditions. In spatial omics, you also want spatial markers—genes whose expression varies with location, forming bands, niches, edges, or gradients. These are captured by spatially aware models that consider coordinates and adjacency, not just group labels.

Methods such as SpatialDE and its successors (for example, SPARK‑X) test whether a gene shows significant spatial structure, classify pattern length scales, and scale to large tissues. Practically, this means you’ll keep two sets of gene lists on hand: cluster markers that help label cell types, and SVGs that reveal tissue architecture. Expect overlap in some genes, but not all; spatial organization is a different signal than between‑cluster variance.

Neighborhoods and interactions: learning tissue architecture

Because spatial assays preserve adjacency, you can quantify “who lives next to whom” rather than infer proximity from shared expression alone. A common pattern is to cluster spots or cells, compute a spatial graph, and measure neighborhood enrichment between cluster pairs. If endothelial and perivascular clusters are enriched as neighbors across the tissue, that canonical pairing validates your segmentation and clustering; if unexpected neighbors consistently appear at tumor margins, that becomes a hypothesis about a niche.

Toolkits make this concrete: you build a spatial connectivity matrix from coordinates, then run a permutation test to score over‑ and under‑representation of neighboring cluster pairs. You can also summarize neighborhoods as “niches,” compute co‑occurrence along gradients, or derive spatial lag features to feed into downstream models. The important behavioral shift for an analyst is to treat proximity as data, not just as a pretty overlay under UMAPs.

What each assay unlocks—and when to combine them

So what can you actually achieve with scRNA‑seq that you can’t with spatial omics, and vice versa?

With scRNA‑seq, you resolve fine‑grained cell states, continuous trajectories, rare subtypes, and modality‑agnostic effects without worrying about optical limits or segmentation edge cases. You can scale to hundreds of thousands of cells and build references that generalize. Your Achilles’ heel is context: without a map, you don’t know where a state lives or which cells surround it.

Spatial assays give you that map. You uncover tissue architecture at multiple scales, detect morphogen gradients, locate interfaces such as tumor–stroma boundaries, quantify cell neighborhoods, and spot microenvironments where gene programs change with location. In imaging‑based assays with molecule tables, you even study subcellular localization patterns—think nuclear versus cytoplasmic enrichment of transcripts for a gene set—and link morphology to expression via segmentation metrics.

The sweet spot is integration. Reference scRNA‑seq defines cell states; spatial data tells you where those states are and with whom they interact. Label‑transfer methods align single‑cell references to spatial observations to annotate spots or cells. Deconvolution methods estimate cell‑type proportions per spot, crucial when one observation contains a mixture of types. Benchmarking studies comparing many approaches find that deep‑learning alignment methods (for example, Tangram, gimVI, SpaGE) often excel at predicting spatial distributions of transcripts, while dedicated deconvolution methods (for example, cell2location, SpatialDWLS, RCTD) perform best for estimating cell‑type mixtures. In practice, analysts pair a deconvolution tool for composition with an alignment tool for continuous expression mapping to exploit both strengths.

A quick note on outputs from modern in situ platforms underscores why integration works. Alongside cell‑level expression, vendors provide detailed per‑transcript tables with coordinates, quality scores, and segmentation links, plus cell‑summary files with areas and centroids. These structured outputs make it straightforward to harmonize with single‑cell references, because you can operate at the cell level when trustworthy, or at the molecule level when you need finer spatial precision.

Summary / Takeaways

At a glance, scRNA‑seq and spatial omics share code and concepts. Under the hood, their data structures force different habits. Single‑cell analysis assumes one observation per cell and fights doublets; spatial analysis often starts with mixtures or segments and uses geometry to recover niches and boundaries. HVGs and cluster markers remain essential, but spatial markers add a new axis of signal that only coordinates can reveal. Neighborhood statistics convert pretty maps into quantitative tests, and integration methods marry state resolution to tissue context.

If you’re deciding where to start, lead with your biological question. If your priority is discovering novel states or mapping differentiation without regard to location, scRNA‑seq gives you power and scale. If you want to see architecture, gradients, and interactions in situ, spatial omics is the right lens. And if you want both, don’t choose—combine: deconvolve spot mixtures to quantify composition, align single‑cell states to tissue to localize programs, and test whether those programs depend on where cells live.

Further Reading