snRNA-seq in Seurat: what to question at each step

Human kidney, 3 control vs 3 diabetic (GSE131882), from Cell Ranger output to pathways

Author

Andrew Milner

Every section has the same three parts: the decision, the default used here, and when to deviate.

Code
suppressPackageStartupMessages({
  library(Seurat); library(SoupX); library(scDblFinder); library(SingleCellExperiment)
  library(scuttle); library(harmony); library(DESeq2); library(fgsea); library(msigdbr)
  library(Matrix); library(ggplot2); library(patchwork); library(dplyr)
})
set.seed(1234)
options(future.globals.maxSize = 8 * 1024^3)
dir.create("results", showWarnings = FALSE)
ss <- read.csv(params$samplesheet)
stopifnot(all(c("sample", "condition", "path") %in% names(ss)), all(dir.exists(ss$path)))
ss
      sample condition                            path
1  control_1   control  data/cellranger/control_1/outs
2  control_2   control  data/cellranger/control_2/outs
3  control_3   control  data/cellranger/control_3/outs
4 diabetic_1  diabetic data/cellranger/diabetic_1/outs
5 diabetic_2  diabetic data/cellranger/diabetic_2/outs
6 diabetic_3  diabetic data/cellranger/diabetic_3/outs

1. Ambient RNA

Decision: correct or not. Default: SoupX on the raw droplet matrix, per sample. Deviate: CellBender if you have a GPU; skip only if the estimated contamination is trivial (rho under about 2%) and you say so.

Nuclei preps lyse cytoplasm into the buffer, so highly expressed transcripts from abundant cell types show up everywhere. In kidney that means proximal tubule genes in every cluster. The uncorrected counts are kept as a second assay so the effect can be checked later.

Code
read_one <- function(dir) {
  filt <- Read10X(file.path(dir, "filtered_feature_bc_matrix"))
  raw  <- Read10X(file.path(dir, "raw_feature_bc_matrix"))
  if (is.list(filt)) { filt <- filt[[1]]; raw <- raw[[1]] }
  quick <- CreateSeuratObject(filt) |>
    NormalizeData(verbose = FALSE) |> FindVariableFeatures(verbose = FALSE) |>
    ScaleData(verbose = FALSE) |> RunPCA(verbose = FALSE) |>
    FindNeighbors(dims = 1:30, verbose = FALSE) |> FindClusters(resolution = 0.8, verbose = FALSE)
  sc <- SoupChannel(raw, filt)
  sc <- setClusters(sc, setNames(as.character(quick$seurat_clusters), colnames(quick)))
  sc <- autoEstCont(sc, doPlot = FALSE)
  list(corrected = adjustCounts(sc, roundToInt = TRUE), uncorrected = filt,
       rho = unique(sc$metaData$rho))
}
raw_list <- lapply(setNames(ss$path, ss$sample), read_one)
data.frame(sample = ss$sample, rho = round(sapply(raw_list, `[[`, "rho"), 3))
               sample   rho
control_1   control_1 0.032
control_2   control_2 0.037
control_3   control_3 0.047
diabetic_1 diabetic_1 0.026
diabetic_2 diabetic_2 0.041
diabetic_3 diabetic_3 0.035

2. Doublets

Decision: when and how. Default: scDblFinder per sample, after empty droplet removal and before strict QC. Deviate: raise the expected rate for overloaded lanes; inspect clusters that co-express markers of two lineages regardless of the call.

Doublets only form within a capture, so this never runs on merged data. Filtering low-quality nuclei first changes the population the simulated doublets are drawn from.

Code
objs <- lapply(ss$sample, function(s) {
  x <- raw_list[[s]]
  o <- CreateSeuratObject(x$corrected, project = s, min.cells = 0)
  o[["uncorrected"]] <- CreateAssay5Object(counts = x$uncorrected[rownames(o), colnames(o)])
  sce <- scDblFinder(SingleCellExperiment(list(counts = x$corrected)))
  o$doublet_class <- as.character(sce$scDblFinder.class)
  o$doublet_score <- sce$scDblFinder.score
  o$sample <- s
  o$condition <- ss$condition[ss$sample == s]
  o[["percent.mt"]] <- PercentageFeatureSet(o, pattern = "^MT-")
  o
})
names(objs) <- ss$sample
rm(raw_list); invisible(gc())

3. QC

Decision: thresholds. Default: per-sample outliers at 3 MADs on log counts and log features, with a floor on the mito cutoff. Deviate: loosen when a real cell type sits in a tail (low-RNA immune cells, large proximal tubule nuclei); tighten after clustering, not before.

Fixed cutoffs copied between datasets are the most common error. In nuclei, percent mito should be near zero, so it flags debris and cytoplasmic carryover and is not a viability metric. Because the median is near zero, a pure MAD rule would be too strict, so the cutoff is never below 5%.

Code
qc_tab <- list()
objs <- lapply(objs, function(o) {
  lowc  <- isOutlier(o$nCount_RNA, nmads = 3, type = "lower", log = TRUE)
  highc <- isOutlier(o$nCount_RNA, nmads = 3, type = "higher", log = TRUE)
  lowf  <- isOutlier(o$nFeature_RNA, nmads = 3, type = "lower", log = TRUE)
  mt_cut <- max(median(o$percent.mt) + 3 * mad(o$percent.mt), 5)
  o$qc_fail <- lowc | highc | lowf | o$percent.mt > mt_cut
  qc_tab[[o$sample[1]]] <<- data.frame(
    sample = o$sample[1], nuclei = ncol(o), mt_cutoff = round(mt_cut, 2),
    qc_fail = sum(o$qc_fail), doublets = sum(o$doublet_class == "doublet"),
    kept = sum(!o$qc_fail & o$doublet_class == "singlet"))
  o
})
do.call(rbind, qc_tab)
               sample nuclei mt_cutoff qc_fail doublets kept
control_1   control_1   7057         5      31      610 6416
control_2   control_2   4308         5     120      317 3881
control_3   control_3   6726         5       0      662 6064
diabetic_1 diabetic_1   5445         5       4      394 5047
diabetic_2 diabetic_2   3872         5       4      240 3628
diabetic_3 diabetic_3   3683         5      10      238 3435
Code
md <- do.call(rbind, lapply(objs, function(o) o@meta.data))
ggplot(md, aes(nCount_RNA, nFeature_RNA, colour = qc_fail | doublet_class == "doublet")) +
  geom_point(size = 0.2, alpha = 0.4) + scale_x_log10() + scale_y_log10() +
  facet_wrap(~sample, nrow = 1) + labs(colour = "removed") + theme_bw()

Code
objs <- lapply(objs, function(o) subset(o, subset = qc_fail == FALSE & doublet_class == "singlet"))
obj <- merge(objs[[1]], objs[-1], add.cell.ids = names(objs))
rm(objs); invisible(gc())
obj
An object of class Seurat 
77212 features across 28471 samples within 2 assays 
Active assay: RNA (38606 features, 0 variable features)
 6 layers present: counts.control_1, counts.control_2, counts.control_3, counts.diabetic_1, counts.diabetic_2, counts.diabetic_3
 1 other assay present: uncorrected

4. Normalization

Decision: which normalization feeds which step. Default: SCTransform per sample for PCA, clustering and UMAP; log-normalized RNA for marker tests and plots; ambient-corrected counts for pseudobulk. Deviate: log-normalization throughout is a valid simpler choice and usually gives very similar clusters.

After merge, each sample is its own layer, so SCTransform fits one model per sample.

Code
obj <- SCTransform(obj, assay = "RNA", vst.flavor = "v2", verbose = FALSE)
obj <- RunPCA(obj, npcs = 50, verbose = FALSE)
ElbowPlot(obj, ndims = 50)

5. Integration

Decision: integrate or not. Default: look at the unintegrated embedding first; apply Harmony on sample if nuclei of the same type separate by sample. The notebook runs it either way, so you can compare the two embeddings below. Deviate: skip integration when samples already mix; never use integrated values for differential expression.

Code
dims <- 1:params$npcs
obj <- RunUMAP(obj, reduction = "pca", dims = dims, reduction.name = "umap.unint", verbose = FALSE)
obj <- RunHarmony(obj, group.by.vars = "sample", reduction.use = "pca", dims.use = dims,
                  reduction.save = "harmony", verbose = FALSE)
obj <- RunUMAP(obj, reduction = "harmony", dims = dims, reduction.name = "umap", verbose = FALSE)
DimPlot(obj, reduction = "umap.unint", group.by = "sample") + ggtitle("Unintegrated") |
  DimPlot(obj, reduction = "umap", group.by = "sample") + ggtitle("Harmony")

Code
obj <- FindNeighbors(obj, reduction = "harmony", dims = dims, verbose = FALSE)
obj <- FindClusters(obj, resolution = params$resolution, verbose = FALSE)
round(prop.table(table(obj$seurat_clusters, obj$sample), 1), 2)
    
     control_1 control_2 control_3 diabetic_1 diabetic_2 diabetic_3
  0       0.24      0.20      0.25       0.19       0.07       0.06
  1       0.23      0.26      0.21       0.19       0.06       0.05
  2       0.29      0.14      0.23       0.17       0.07       0.10
  3       0.16      0.12      0.23       0.28       0.15       0.07
  4       0.27      0.10      0.14       0.05       0.14       0.30
  5       0.30      0.09      0.14       0.09       0.12       0.25
  6       0.10      0.13      0.22       0.17       0.22       0.16
  7       0.15      0.10      0.35       0.22       0.12       0.07
  8       0.28      0.08      0.21       0.20       0.11       0.12
  9       0.12      0.12      0.18       0.11       0.28       0.20
  10      0.28      0.08      0.15       0.25       0.15       0.10
  11      0.28      0.06      0.14       0.34       0.16       0.02
  12      0.18      0.06      0.28       0.20       0.12       0.17
  13      0.06      0.04      0.06       0.24       0.55       0.05
  14      0.27      0.07      0.19       0.21       0.16       0.10
  15      0.09      0.02      0.38       0.09       0.36       0.06
  16      0.20      0.04      0.19       0.14       0.29       0.15
  17      0.97      0.01      0.01       0.00       0.00       0.00

A cluster made almost entirely of one sample is either biology specific to that donor or a leftover artifact. Check its QC metrics before believing it. In our run, cluster 17 (67 nuclei) came almost entirely from control_1. Its markers match intercalated type A cells, so we gave it that label, which pools it with cluster 7 for the comparison between conditions.

Code
VlnPlot(obj, c("nFeature_RNA", "percent.mt", "doublet_score"), pt.size = 0, ncol = 3)

6. Markers

Decision: how to describe clusters. Default: Wilcoxon on log-normalized RNA. Deviate: none needed, as long as these p-values are treated as descriptive. Nuclei are not replicates.

Code
DefaultAssay(obj) <- "RNA"
obj <- JoinLayers(obj, assay = "RNA")
obj <- NormalizeData(obj, verbose = FALSE)
markers <- FindAllMarkers(obj, only.pos = TRUE, min.pct = 0.25, logfc.threshold = 0.5, verbose = FALSE)
write.csv(markers, "results/cluster_markers.csv", row.names = FALSE)
markers |> group_by(cluster) |> slice_max(avg_log2FC, n = 5) |> summarise(top = paste(gene, collapse = ", "))
# A tibble: 18 × 2
   cluster top                                                         
   <fct>   <chr>                                                       
 1 0       CDHR5, MIOX, KHK, FTCD, AMN                                 
 2 1       ENSG00000267175, SLC5A12, LYPLAL1-AS1, SLC36A2, SORCS1      
 3 2       SLC12A3, ENSG00000271945, TRIM50, LINC01896, ENSG00000242029
 4 3       LINC03051, LINC01099, ENSG00000289013, SNTG1, SLC8A1        
 5 4       PAPPA2, CLDN10-AS1, ENSG00000288015, ACP3, ENSG00000286481  
 6 5       TMEM207, CLDN16, GP2, UMOD, RP1                             
 7 6       FXYD4, ENSG00000285876, ELF5, ROR2, PWRN1                   
 8 7       LINC01230, ENSG00000256249, CNTNAP5, DMRT2, SHOC1           
 9 8       DNASE1L3, FLT1, PLAT, EMCN, ROBO4                           
10 9       ENSG00000285695, DCC, ENSG00000262198, MYO3A, SATB2         
11 10      KIRREL3, SLC4A11, MGAT4C, CADM2, LINC01435                  
12 11      INSRR, TLDC2, SLC26A4, NTRK1, CSMD3                         
13 12      PTPRQ, ENSG00000257042, ENSG00000230027, PTPRO, ADAMTS19    
14 13      IKZF3, ITGAL, THEMIS, TMC8, IKZF1                           
15 14      HPSE2, CSPG4, ENSG00000250049, HEYL, LDB3                   
16 15      C7, COL1A2, ABCA8, MOXD1, SERPINE1                          
17 16      ENSG00000285691, IL33, LINC00639, FBLN2, DKK2               
18 17      GJD2-DT, LRRC52-AS1, ENSG00000274244, ENSG00000272574, LEF1 

7. Annotation

Decision: where labels come from. Default: reference transfer when a good reference exists, checked against canonical markers, then approved by a person at cluster level. Deviate: no reference for your tissue or species means markers only.

Code
canonical <- list(
  Podocyte = c("NPHS1", "NPHS2"), PEC = c("CFH", "VCAM1"), PT = c("LRP2", "CUBN", "SLC34A1"),
  TAL = c("SLC12A1", "UMOD"), DCT = c("SLC12A3"), CNT = c("SLC8A1", "CALB1"), PC = c("AQP2"),
  IC_A = c("SLC4A1", "SLC26A7"), IC_B = c("SLC26A4"), Endothelial = c("EMCN", "FLT1"),
  Stromal = c("PDGFRB", "ITGA8"), Immune = c("PTPRC"))
DotPlot(obj, features = canonical, assay = "RNA") + RotatedAxis() + theme(strip.text = element_text(size = 7))

Code
# Azimuth downloads the kidney reference the first time, so this step needs internet
# and a writable R library (run.sh sets one up in .Rlib).
az <- Azimuth::RunAzimuth(obj, reference = "kidneyref")
stopifnot("predicted.annotation.l2" %in% names(az@meta.data))
obj$reference_label <- az@meta.data[colnames(obj), "predicted.annotation.l2"]
rm(az)

The proposed label for each cluster is written to results/annotation_proposed.csv. Review it against the dot plot and the marker table, edit the celltype column, and save it as annotation_approved.csv in the project folder. The notebook uses the approved file when it exists. This repository ships the file from our run, and the notebook stops if its clusters and sizes do not match yours. In that case, delete it, render once, and review your own proposal.

Code
proposed <- obj@meta.data |> group_by(cluster = seurat_clusters) |>
  summarise(n = n(),
            reference_majority = if (all(is.na(reference_label))) NA_character_ else names(which.max(table(reference_label))),
            agreement = if (all(is.na(reference_label))) NA_real_ else round(max(table(reference_label)) / n(), 2)) |>
  mutate(celltype = ifelse(is.na(reference_majority), paste0("cluster_", cluster), reference_majority))
write.csv(proposed, "results/annotation_proposed.csv", row.names = FALSE)
ann <- if (file.exists("annotation_approved.csv")) read.csv("annotation_approved.csv") else proposed
# Labels belong to specific clusters. Stop if the approved file was made from different ones.
sizes <- table(obj$seurat_clusters)
if (!setequal(as.character(ann$cluster), names(sizes)) ||
    any(ann$n != sizes[as.character(ann$cluster)]))
  stop("annotation_approved.csv does not match these clusters. Delete it, render, and review results/annotation_proposed.csv.")
obj$celltype <- ann$celltype[match(as.character(obj$seurat_clusters), as.character(ann$cluster))]
stopifnot(!anyNA(obj$celltype))
ann
   cluster    n                           reference_majority agreement
1        0 4532         Proximal Tubule Epithelial Segment 1      0.85
2        1 3427         Proximal Tubule Epithelial Segment 1      0.88
3        2 3412                     Distal Convoluted Tubule      0.99
4        3 2651                            Connecting Tubule      0.97
5        4 2487                Cortical Thick Ascending Limb      0.73
6        5 2196                Cortical Thick Ascending Limb      0.78
7        6 1888                            Connecting Tubule      0.59
8        7 1610 Cortical Collecting Duct Intercalated Type A      0.99
9        8 1605            Peritubular Capilary Endothelial       0.62
10       9 1197                  Descending Thin Limb Type 2      0.72
11      10  840                          Parietal Epithelial      0.97
12      11  723                          Intercalated Type B      0.98
13      12  635                                     Podocyte      0.99
14      13  420                                            T      0.41
15      14  342   Cortical Vascular Smooth Muscle / Pericyte      0.41
16      15  284                                   Fibroblast      0.82
17      16  155    Afferent / Efferent Arteriole Endothelial      0.96
18      17   67 Cortical Collecting Duct Intercalated Type A      0.97
                                       celltype
1          Proximal Tubule Epithelial Segment 1
2          Proximal Tubule Epithelial Segment 1
3                      Distal Convoluted Tubule
4                             Connecting Tubule
5                 Cortical Thick Ascending Limb
6                 Cortical Thick Ascending Limb
7                                Principal Cell
8  Cortical Collecting Duct Intercalated Type A
9             Peritubular Capillary Endothelial
10                  Descending Thin Limb Type 2
11                          Parietal Epithelial
12                          Intercalated Type B
13                                     Podocyte
14                                       T / NK
15   Cortical Vascular Smooth Muscle / Pericyte
16                                   Fibroblast
17    Afferent / Efferent Arteriole Endothelial
18 Cortical Collecting Duct Intercalated Type A
Code
DimPlot(obj, reduction = "umap", group.by = "celltype", label = TRUE, repel = TRUE) + NoLegend() |
  DimPlot(obj, reduction = "umap", group.by = "condition")

8. Differential expression between conditions

Decision: unit of replication. Default: pseudobulk, summing counts per cell type per sample, then DESeq2 with samples as replicates. Deviate: mixed models when you have many donors and need covariates at the cell level. Never a per-nucleus Wilcoxon between conditions.

Counts here are the ambient-corrected integers. Whether to use corrected or uncorrected counts for pseudobulk is an open question, so the uncorrected assay is kept and the comparison is one argument away.

Code
pseudobulk <- function(obj, assay = "RNA") {
  cts <- GetAssayData(JoinLayers(obj[[assay]]), layer = "counts")
  grp <- factor(paste(obj$celltype, obj$sample, sep = "__"))
  mm <- sparse.model.matrix(~ 0 + grp); colnames(mm) <- levels(grp)
  list(counts = as.matrix(cts %*% mm), ncells = table(grp))
}
pb <- pseudobulk(obj, "RNA")
run_de <- function(ct, min_cells = 10) {
  cols <- names(pb$ncells)[sub("__.*", "", names(pb$ncells)) == ct & pb$ncells >= min_cells]
  cd <- data.frame(sample = sub(".*__", "", cols), row.names = cols)
  cd$condition <- factor(ss$condition[match(cd$sample, ss$sample)], levels = c("control", "diabetic"))
  left_out <- setdiff(ss$sample, cd$sample)
  if (length(left_out)) message(ct, ": left out ", paste(left_out, collapse = ", "), " (fewer than ", min_cells, " nuclei)")
  if (any(table(cd$condition) < 2)) {
    message(ct, ": not tested, fewer than 2 samples in a condition")
    return(NULL)
  }
  m <- pb$counts[, cols]
  m <- m[rowSums(m >= 10) >= min(table(cd$condition)), ]
  dds <- DESeq(DESeqDataSetFromMatrix(m, cd, ~ condition), quiet = TRUE)
  res <- as.data.frame(results(dds, contrast = c("condition", "diabetic", "control")))
  res$gene <- rownames(res); res$celltype <- ct
  res[order(res$pvalue), ]
}
de <- Filter(Negate(is.null), lapply(setNames(nm = unique(obj$celltype)), run_de))
converting counts to integer mode
converting counts to integer mode
converting counts to integer mode
converting counts to integer mode
converting counts to integer mode
converting counts to integer mode
converting counts to integer mode
converting counts to integer mode
converting counts to integer mode
converting counts to integer mode
converting counts to integer mode
converting counts to integer mode
converting counts to integer mode
Afferent / Efferent Arteriole Endothelial: left out control_2 (fewer than 10 nuclei)
converting counts to integer mode
Fibroblast: left out control_2 (fewer than 10 nuclei)
converting counts to integer mode
Code
de_all <- do.call(rbind, de)
write.csv(de_all, "results/pseudobulk_DE.csv", row.names = FALSE)
de_all |> group_by(celltype) |> summarise(tested = n(), sig = sum(padj < 0.05, na.rm = TRUE)) |> arrange(desc(sig))
# A tibble: 15 × 3
   celltype                                     tested   sig
   <chr>                                         <int> <int>
 1 Cortical Thick Ascending Limb                 13081    21
 2 Descending Thin Limb Type 2                   10171    20
 3 Proximal Tubule Epithelial Segment 1          13582    19
 4 Peritubular Capillary Endothelial              7532    14
 5 Cortical Collecting Duct Intercalated Type A  10750     9
 6 Parietal Epithelial                            7444     9
 7 Connecting Tubule                             11751     2
 8 Podocyte                                       7698     2
 9 Afferent / Efferent Arteriole Endothelial      2613     1
10 Cortical Vascular Smooth Muscle / Pericyte     3310     1
11 Principal Cell                                10964     1
12 Distal Convoluted Tubule                      12175     0
13 Fibroblast                                     3366     0
14 Intercalated Type B                            5542     0
15 T / NK                                         1510     0

With 3 vs 3 human samples, power is low and some cell types will return few or no genes at FDR 5%. That is the honest answer for this design, and it is the reason the next step uses the full ranked list.

9. Pathways

Decision: enrichment method and gene sets. Default: GSEA with fgsea on every tested gene ranked by the DESeq2 statistic, using Hallmark and Reactome. Deviate: over-representation is fine when you have a confident DEG list, but the background must be the genes tested in that cell type, not the genome. GO and KEGG largely repeat Reactome, so add them when a reviewer asks.

Code
get_sets <- function(collection, sub = NULL) {
  f <- names(formals(msigdbr))
  a <- list(species = "Homo sapiens")
  if ("collection" %in% f) { a$collection <- collection; if (!is.null(sub)) a$subcollection <- sub }
  else { a$category <- collection; if (!is.null(sub)) a$subcategory <- sub }
  d <- do.call(msigdbr, a)
  split(d$gene_symbol, d$gs_name)
}
sets <- c(get_sets("H"), get_sets("C2", "CP:REACTOME"))
length(sets)
[1] 1889
Code
gsea <- lapply(de, function(res) {
  r <- res[!is.na(res$stat), ]
  stats <- sort(setNames(r$stat, r$gene), decreasing = TRUE)
  out <- fgsea(sets, stats, minSize = 15, maxSize = 500)
  out$celltype <- res$celltype[1]
  out[order(out$padj), ]
})
gsea_all <- do.call(rbind, gsea)
gsea_out <- as.data.frame(gsea_all)
gsea_out$leadingEdge <- vapply(gsea_out$leadingEdge, paste, "", collapse = ";")
write.csv(gsea_out, "results/gsea.csv", row.names = FALSE)
Code
top_ct <- names(which.max(sapply(gsea, function(x) sum(x$padj < 0.05, na.rm = TRUE))))
gsea[[top_ct]] |> as.data.frame() |> filter(!is.na(padj)) |> slice_min(padj, n = 20, with_ties = FALSE) |>
  ggplot(aes(NES, reorder(pathway, NES), fill = padj < 0.05)) + geom_col() +
  labs(y = NULL, title = paste("GSEA, diabetic vs control:", top_ct)) + theme_bw() +
  theme(axis.text.y = element_text(size = 7))

Over-representation with the correct background, for comparison:

Code
res <- de[[top_ct]]
sig <- res$gene[which(res$padj < 0.05)]
t2g <- stack(sets)[, 2:1]
if (length(sig) >= 10) {
  ora <- as.data.frame(clusterProfiler::enricher(sig, universe = res$gene, TERM2GENE = t2g))
  if (nrow(ora) == 0) cat("No gene set is enriched among the", length(sig), "significant genes in", top_ct, "\n")
  head(ora[, c("ID", "GeneRatio", "BgRatio", "p.adjust")], 10)
} else {
  cat("Fewer than 10 significant genes in", top_ct, "so ORA is not informative here.\n")
}
No gene set is enriched among the 21 significant genes in Cortical Thick Ascending Limb 
[1] ID        GeneRatio BgRatio   p.adjust 
<0 rows> (or 0-length row.names)

With only a few dozen significant genes, over-representation usually finds nothing. That is why GSEA, which uses every gene’s ranking, is the main pathway method here.

Save

Code
saveRDS(obj, "results/kidney_snrna_annotated.rds")
sessionInfo()
R version 4.6.1 (2026-06-24)
Platform: x86_64-pc-linux-gnu
Running under: Ubuntu 24.04.4 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.26.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] stats4    stats     graphics  grDevices utils     datasets  methods  
[8] base     

other attached packages:
 [1] shinyBS_0.65.0              future_1.82.0              
 [3] dplyr_1.2.1                 patchwork_1.3.2            
 [5] ggplot2_4.0.3               Matrix_1.7-6               
 [7] msigdbr_26.1.1              fgsea_1.38.0               
 [9] DESeq2_1.52.0               harmony_2.0.5              
[11] Rcpp_1.1.2                  scuttle_1.22.0             
[13] scDblFinder_1.26.9          SingleCellExperiment_1.34.0
[15] SummarizedExperiment_1.42.0 Biobase_2.72.0             
[17] GenomicRanges_1.64.0        Seqinfo_1.2.0              
[19] IRanges_2.46.0              S4Vectors_0.50.3           
[21] BiocGenerics_0.58.1         generics_0.1.4             
[23] MatrixGenerics_1.24.0       matrixStats_1.5.0          
[25] SoupX_1.6.2                 Seurat_6.0.0               
[27] SeuratObject_5.4.0          sp_2.2-4                   

loaded via a namespace (and not attached):
  [1] R.methodsS3_1.8.2                 dichromat_2.0-1                  
  [3] DT_0.34.0                         Biostrings_2.80.2                
  [5] vctrs_0.7.3                       kidneyref.SeuratData_1.0.2       
  [7] ggtangle_0.1.5                    digest_0.6.39                    
  [9] png_0.1-9                         ggrepel_0.9.8                    
 [11] parallelly_1.50.0                 fontLiberation_0.1.0             
 [13] MASS_7.3-66                       Signac_1.17.1                    
 [15] reshape2_1.4.5                    qvalue_2.44.0                    
 [17] httpuv_1.6.17                     withr_3.0.3                      
 [19] ggrastr_1.0.2                     xfun_0.60                        
 [21] ggfun_0.2.2                       EnsDb.Hsapiens.v86_2.99.0        
 [23] memoise_2.0.1                     ggbeeswarm_0.7.3                 
 [25] gson_0.2.2                        clusterProfiler_4.20.3           
 [27] systemfonts_1.3.2                 tidytree_0.4.8                   
 [29] gtools_3.9.5                      pbapply_1.7-5                    
 [31] R.oo_1.27.1                       KEGGREST_1.52.2                  
 [33] promises_1.5.0                    otel_0.2.0                       
 [35] httr_1.4.9                        restfulr_0.0.17                  
 [37] globals_0.20.0                    rhdf5filters_1.24.1              
 [39] ps_1.9.3                          rhdf5_2.56.1                     
 [41] UCSC.utils_1.8.0                  DOSE_4.6.0                       
 [43] processx_3.9.0                    curl_7.1.0                       
 [45] ScaledMatrix_1.20.0               polyclip_1.10-7                  
 [47] SparseArray_1.12.3                xtable_1.8-8                     
 [49] stringr_1.6.0                     evaluate_1.0.5                   
 [51] S4Arrays_1.12.1                   irlba_2.4.1                      
 [53] hdf5r_1.3.16                      magrittr_2.0.5                   
 [55] later_1.4.8                       viridis_0.6.5                    
 [57] ggtree_4.2.1                      lattice_0.22-9                   
 [59] glmGamPoi_1.24.0                  future.apply_1.21.0              
 [61] scattermore_1.2                   XML_3.99-0.25                    
 [63] cowplot_1.2.0                     RcppAnnoy_0.0.23                 
 [65] pillar_1.11.1                     nlme_3.1-170                     
 [67] pwalign_1.8.0                     caTools_1.18.4                   
 [69] compiler_4.6.1                    beachmat_2.28.0                  
 [71] RSpectra_0.16-2                   stringi_1.8.9                    
 [73] GenomicAlignments_1.48.0          plyr_1.8.9                       
 [75] crayon_1.5.3                      abind_1.4-8                      
 [77] BiocIO_1.22.0                     scater_1.40.2                    
 [79] gridGraphics_0.5-1                googledrive_2.2.0                
 [81] locfit_1.5-9.12                   bit_4.6.0                        
 [83] fastmatch_1.1-8                   codetools_0.2-20                 
 [85] BiocSingular_1.28.1               SeuratData_0.2.2.9002            
 [87] plotly_4.12.1                     mime_0.13                        
 [89] splines_4.6.1                     fastDummies_1.7.6                
 [91] tidydr_0.0.7                      sparseMatrixStats_1.24.0         
 [93] scrapper_1.6.3                    cellranger_1.1.0                 
 [95] knitr_1.52                        blob_1.3.0                       
 [97] utf8_1.2.6                        seqLogo_1.78.0                   
 [99] AnnotationFilter_1.36.0           fs_2.1.0                         
[101] listenv_1.1.0                     DelayedMatrixStats_1.34.0        
[103] ggplotify_0.1.4                   tibble_3.3.1                     
[105] callr_3.8.0                       statmod_1.5.2                    
[107] tweenr_2.0.3                      pkgconfig_2.0.3                  
[109] tools_4.6.1                       cachem_1.1.0                     
[111] RhpcBLASctl_0.23-42               cigarillo_1.2.1                  
[113] RSQLite_3.53.3                    viridisLite_0.4.3                
[115] DBI_1.3.0                         fastmap_1.2.0                    
[117] rmarkdown_2.32                    scales_1.4.0                     
[119] grid_4.6.1                        ica_1.0-3                        
[121] shinydashboard_0.7.3              Rsamtools_2.28.0                 
[123] dotCall64_1.2                     RANN_2.6.3                       
[125] farver_2.1.2                      scatterpie_0.2.6                 
[127] yaml_2.3.12                       rtracklayer_1.72.0               
[129] cli_3.6.6                         purrr_1.2.2                      
[131] lifecycle_1.0.5                   uwot_0.2.5                       
[133] presto_1.1.0                      bluster_1.22.0                   
[135] BSgenome.Hsapiens.UCSC.hg38_1.4.5 BiocParallel_1.46.0              
[137] gtable_0.3.6                      rjson_0.2.23                     
[139] ggridges_0.5.7                    progressr_1.1.0                  
[141] parallel_4.6.1                    ape_5.8-1                        
[143] limma_3.68.5                      enrichit_0.2.7                   
[145] jsonlite_2.0.0                    edgeR_4.10.7                     
[147] RcppHNSW_0.7.0                    TFBSTools_1.50.0                 
[149] bitops_1.1-0                      bit64_4.8.6                      
[151] assertthat_0.2.1                  xgboost_3.2.1.1                  
[153] Rtsne_0.17                        yulab.utils_0.2.5                
[155] BiocNeighbors_2.6.0               aisdk_1.4.12                     
[157] metapod_1.20.0                    GOSemSim_2.38.3                  
[159] dqrng_0.4.1                       shinyjs_2.1.1                    
[161] SeuratDisk_0.0.0.9021             R.utils_2.13.0                   
[163] lazyeval_0.2.3                    shiny_1.14.0                     
[165] Azimuth_0.5.1                     htmltools_0.5.9                  
[167] enrichplot_1.32.1                 GO.db_3.23.1                     
[169] sctransform_0.4.3                 rappdirs_0.3.4                   
[171] ensembldb_2.36.1                  glue_1.8.1                       
[173] TFMPvalue_1.0.0                   spam_2.11-4                      
[175] googlesheets4_1.1.3               httr2_1.3.0                      
[177] XVector_0.52.0                    gdtools_0.5.3                    
[179] RCurl_1.98-1.20                   treeio_1.36.1                    
[181] scran_1.40.0                      BSgenome_1.80.0                  
[183] gridExtra_2.3.1                   JASPAR2020_0.99.10               
[185] igraph_2.3.4                      R6_2.6.1                         
[187] tidyr_1.3.2                       ggiraph_0.9.6                    
[189] RcppRoll_0.4.0                    labeling_0.4.3                   
[191] GenomicFeatures_1.64.0            cluster_2.1.8.3                  
[193] Rhdf5lib_2.0.0                    gargle_1.7.0                     
[195] aplot_0.3.2                       GenomeInfoDb_1.48.0              
[197] DirichletMultinomial_1.54.1       DelayedArray_0.38.2              
[199] tidyselect_1.2.1                  vipor_0.4.7                      
[201] ProtGenerics_1.44.0               ggforce_0.5.0                    
[203] fontBitstreamVera_0.1.1           AnnotationDbi_1.74.0             
[205] rsvd_2.0.0                        KernSmooth_2.23-26               
[207] S7_0.2.2                          fontquiver_0.2.1                 
[209] data.table_1.18.6.1               htmlwidgets_1.6.4                
[211] RColorBrewer_1.1-3                pls_2.9-0                        
[213] rlang_1.3.0                       ggnewscale_0.5.2                 
[215] beeswarm_0.4.0