SCEVAN implements a variational segmentation algorithm combined with a hierarchical hidden Markov model to infer copy number alterations from single-cell RNA sequencing data. This document provides a comprehensive description of the methodology.
The preprocessing pipeline consists of several key steps:
Pipeline Steps:
Cells are filtered based on:
Filtering criteria:
\[\text{Keep cell } c \text{ if: } \sum_{g=1}^{G} \mathbb{1}(x_{gc} > 0) \geq 200\]
\[\text{Keep gene } g \text{ if: } \frac{\sum_{c=1}^{C} \mathbb{1}(x_{gc} > 0)}{C} \geq 0.01\]
The Freeman-Tukey transformation is applied to stabilize variance:
\[y_{gc} = \\log\\left(\\sqrt{x_{gc}} + \\sqrt{x_{gc} + 1}\\right)\]
where \(x_{gc}\) is the raw count for gene \(g\) in cell \(c\).
This transformation:
SCEVAN automatically identifies normal (non-malignant) cells using gene set enrichment analysis.
The Mann-Whitney-Wilcoxon Gene Set Test (MWW-GST) evaluates enrichment of cell-type specific signatures:
\[\\text{NES}_s = \\frac{\\bar{R}_s - \\mu_0}{\\sigma_0}\]
where:
Built-in signatures include:
| Cell Type | Description |
|---|---|
| T cells | CD3D, CD3E, CD4, CD8A markers |
| B cells | CD19, CD79A, MS4A1 markers |
| Myeloid | CD14, CD68, ITGAM markers |
| Endothelial | PECAM1, VWF, CDH5 markers |
| Fibroblasts | COL1A1, DCN, FAP markers |
The core segmentation uses VegaMC (Variational Estimator of Genomic Alterations using Multichannel), a greedy algorithm optimizing the objective:
\[\\mathcal{L}(\\mathbf{s}) = \\sum_{i=1}^{K} \\sum_{c=1}^{C} \\left( y_{ic} - \\mu_{s_i,c} \\right)^2 + \\beta K\]
where:
The algorithm uses a priority queue to efficiently merge adjacent segments:
Algorithm: VegaMC Segmentation
Input: Expression matrix Y, parameter β
Output: Segmentation S
1. Initialize: Each probe is a segment
2. Build priority queue Q with merge costs
3. While min(Q) < β:
a. Pop minimum cost merge (i, j)
b. Merge segments i and j
c. Update affected merge costs in Q
4. Return final segmentation S
For each segment, hypothesis tests determine significance:
P-values are computed using t-tests across cells.
An Expectation-Maximization (EM) algorithm assigns copy number states.
Segment means are modeled as a mixture of 5 Gaussian components:
\[p(x) = \\sum_{k=0}^{4} \\pi_k \\mathcal{N}(x | \\mu_k, \\sigma_k^2)\]
| State | CN | Description |
|---|---|---|
| 0 | Homozygous deletion | Deep loss |
| 1 | Hemizygous deletion | Single copy loss |
| 2 | Diploid | Normal |
| 3 | Single copy gain | Amplification |
| 4 | High amplification | Multi-copy gain |
E-step: Compute posterior probabilities
\[\\gamma_{ik} = \\frac{\\pi_k \\mathcal{N}(x_i | \\mu_k, \\sigma_k^2)}{\\sum_{j=0}^{4} \\pi_j \\mathcal{N}(x_i | \\mu_j, \\sigma_j^2)}\]
M-step: Update parameters
\[\\mu_k^{new} = \\frac{\\sum_i \\gamma_{ik} x_i}{\\sum_i \\gamma_{ik}}\]
\[\\sigma_k^{2,new} = \\frac{\\sum_i \\gamma_{ik} (x_i - \\mu_k^{new})^2}{\\sum_i \\gamma_{ik}}\]
Subclones are identified using Louvain community detection on a shared nearest neighbor (SNN) graph:
The Louvain algorithm maximizes modularity:
\[Q = \\frac{1}{2m} \\sum_{ij} \\left[ A_{ij} - \\frac{k_i k_j}{2m} \\right] \\delta(c_i, c_j)\]
where:
Alterations are classified as:
fGSEA (fast Gene Set Enrichment Analysis) identifies enriched pathways:
\[ES = \\max_{j=1}^{n} \\left| \\sum_{i=1}^{j} \\frac{|r_i|^p}{N_R} - \\frac{j - \\text{hit}_j}{N - N_H} \\right|\]
Based on analysis of 106 samples (93,332 cells):
| Metric | SCEVAN | InferCNV | CopyKAT |
|---|---|---|---|
| F1 Score | 0.90 | 0.63 | 0.65 |
| Precision | 0.89 | 0.60 | 0.62 |
| Recall | 0.91 | 0.66 | 0.68 |
| Parameter | Default | Description | Tuning Advice |
|---|---|---|---|
beta_vega |
0.5 | Segmentation granularity | Increase for noisy data |
par_cores |
20 | Parallel cores | Set to available CPUs |
ngenes_chr |
5 | Min genes per chromosome | Lower for sparse data |
perc_genes |
0.1 | Gene expression threshold | Lower for low-coverage |
De Falco, A., et al. (2023). A variational algorithm to detect the clonal copy number substructure of tumors from scRNA-seq data. Nature Communications, 14, 1074.
Mardis, E.R., & Wilson, R.K. (2009). Cancer genome sequencing: a review. Human Molecular Genetics, 18(R2), R163-R168.
Blondel, V.D., et al. (2008). Fast unfolding of communities in large networks. Journal of Statistical Mechanics, P10008.
sessionInfo()
#> R version 4.6.1 (2026-06-24)
#> Platform: x86_64-pc-linux-gnu
#> Running under: Ubuntu 26.04 LTS
#>
#> Matrix products: default
#> BLAS: /usr/lib/x86_64-linux-gnu/openblas-pthread/libblas.so.3
#> LAPACK: /usr/lib/x86_64-linux-gnu/openblas-pthread/libopenblasp-r0.3.32.so; LAPACK version 3.12.0
#>
#> locale:
#> [1] LC_CTYPE=en_US.UTF-8 LC_NUMERIC=C
#> [3] LC_TIME=en_US.UTF-8 LC_COLLATE=en_US.UTF-8
#> [5] LC_MONETARY=en_US.UTF-8 LC_MESSAGES=en_US.UTF-8
#> [7] LC_PAPER=en_US.UTF-8 LC_NAME=C
#> [9] LC_ADDRESS=C LC_TELEPHONE=C
#> [11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C
#>
#> time zone: Etc/UTC
#> tzcode source: system (glibc)
#>
#> attached base packages:
#> [1] stats graphics grDevices utils datasets methods base
#>
#> other attached packages:
#> [1] rmarkdown_2.31
#>
#> loaded via a namespace (and not attached):
#> [1] digest_0.6.39 R6_2.6.1 fastmap_1.2.0 xfun_0.59
#> [5] maketools_1.3.2 cachem_1.1.0 knitr_1.51 htmltools_0.5.9
#> [9] buildtools_1.0.0 lifecycle_1.0.5 cli_3.6.6 sass_0.4.10
#> [13] jquerylib_0.1.4 compiler_4.6.1 sys_3.4.3 tools_4.6.1
#> [17] evaluate_1.0.5 bslib_0.11.0 yaml_2.3.12 otel_0.2.0
#> [21] jsonlite_2.0.0 rlang_1.2.0