概念

理解空间转录组分析。


什么是空间转录组?

空间转录组在保留组织中细胞物理位置的同时测量基因表达。与传统单细胞 RNA 测序不同,它告诉你细胞在哪里,而不只是表达什么。

关键洞见:位置很重要。肿瘤细胞的行为会随着其周围是免疫细胞还是成纤维细胞而改变。


核心分析类型

空间区域

作用:基于相似的基因表达模式对组织区域进行分组。

何时使用:预处理后的第一步。用于识别组织结构,如肿瘤区域、免疫浸润区或组织分层。

How to choose:

  • If your data includes informative histology images, prefer a histology-aware method.

  • If your data is high-resolution single-cell spatial data, prefer graph or deep-learning domain methods.

  • If you want a quick baseline, use clustering-first exploration.

See Methods Reference for the full supported domain methods and defaults.


细胞类型注释 vs 去卷积

这两个概念常被混淆。区别如下:

注释

去卷积

输出

“这个 spot 是 T 细胞”

“这个 spot 中 T 细胞占 60%,巨噬细胞 30%,成纤维细胞 10%”

适用场景

单细胞分辨率数据

基于 spot 的数据(Visium)

假设

每个 spot 只有一种细胞类型

每个 spot 可能包含多种细胞类型

经验法则

  • Xenium、MERFISH、CosMx:用注释(单细胞分辨率)

  • Visium、Slide-seq:用去卷积(每个 spot 多细胞)


细胞通讯

作用:通过配体-受体相互作用识别哪些细胞类型在相互“对话”。

关键概念:细胞 A 表达配体(信号分子),细胞 B 表达受体;如果它们空间上足够接近,可能存在通讯。

物种很重要:请选择正确的数据库:

  • 人类:liana_resource="consensus"

  • 小鼠:liana_resource="mouseconsensus"


RNA Velocity(RNA 速度)

作用:通过比较 spliced 与 unspliced RNA 预测未来的细胞状态。

关键洞见:如果某基因的 unspliced RNA 更多,通常表示正在上调;如果 spliced 更多,表示正在下调。这反映了细胞变化的“方向”。

要求:数据中必须包含 splicedunspliced layers(来自 velocyto、kallisto 或 STARsolo)。


方法选择

Deconvolution

Use deconvolution when a spot contains multiple cell types and you want proportions rather than a single label.

How to choose:

  • start with a fast method for exploration

  • move to a slower, stronger method for final figures

  • prefer methods with explicit spatial modeling if tissue structure matters to the question

See Methods Reference for the full deconvolution method list, defaults, and requirements.


Annotation

Use annotation when your platform already has single-cell resolution or when you want one dominant label per cell/spot.

How to choose:

  • use transfer methods when you have a strong matching reference

  • use marker-based methods when marker genes are well established

  • use automated methods for quick initial labeling, then validate biologically

See Methods Reference for supported annotation methods and exact requirements.


空间统计

Spatial statistics answer different spatial questions.

How to choose:

  • use global autocorrelation when you want one summary statistic for a gene

  • use local hotspot methods when you want to locate spatially enriched regions

  • use neighborhood or co-occurrence analyses when your question is about cell-type organization rather than gene-level spatial patterning

See Methods Reference for the full analysis-type matrix and required inputs.


结果解读

解读去卷积结果

好的去卷积结果通常表现为:

  • 每个 spot 的细胞类型比例之和约为 1.0

  • 能看到已知的组织结构(例如上皮 vs 基质)

  • 比例与组织学特征相关

警示信号:

  • 某一种细胞类型在几乎所有位置占主导(>80%)

  • 比例与预期组织组成不符

  • 不同方法得到的结果差异过大


解读空间统计结果

Moran's I 解释:

  • I > 0:聚集(相似值彼此相邻)

  • I ≈ 0:随机

  • I < 0:离散(不相似值彼此相邻)

p-value:检验该模式相对于随机是否显著。


常见坑

1. Skipping Preprocessing

很多分析失败是因为没有运行预处理。务必先预处理:

"Preprocess the data"

2. Wrong Species Parameter

Cell communication analysis depends on species-specific resources. Use the resource that matches the organism, especially for mouse data.

See Methods Reference for the canonical species and resource settings.

3. Expecting Single-Cell Resolution from Visium

Visium 的一个 spot 含 1–10 个细胞。请用去卷积估计比例,而不是用注释强行赋予单一类型。

4. Using GPU Methods Without GPU

像 Cell2location 这类方法在没有 GPU 时会慢 10–100 倍。你可以:

  • 显式设置 use_gpu=False

  • 使用更适合 CPU 的替代方案(FlashDeconv、RCTD)


工作流模式

标准探索工作流

Load → Preprocess → Domains → Markers → Visualize

适用于:新数据集的初步探索。

基于参考数据的工作流

Load spatial → Load reference → Preprocess both → Deconvolve → Communicate

适用于:你有匹配的单细胞参考数据时。

发表级工作流

Load → Preprocess → Domains → Deconvolve → Statistics → Communication → Velocity

适用于:面向发表的全面分析。