$npx -y skills add GPTomics/bioSkills --skill single-cell-atacProcess and analyze single-cell ATAC-seq data with Signac, ArchR, SnapATAC2, or Cell Ranger ATAC. Use when handling 10X scATAC or 10X Multiome (paired RNA+ATAC) data, performing per-cell QC, choosing between ArchR/Signac/SnapATAC2 ecosystems, building per-cluster consensus peakse
| 1 | ## Version Compatibility |
| 2 | |
| 3 | Reference examples tested with: Cell Ranger ATAC 2.1+, Signac 1.13+, Seurat 5.0+, ArchR 1.0.2+, SnapATAC2 2.8+, AMULET 1.1+, scDblFinder 1.16+, scater 1.30+, scvi-tools 1.1+, GenomicRanges 1.54+, JASPAR2024 0.99+, BSgenome.Hsapiens.UCSC.hg38 1.4+, EnsDb.Hsapiens.v86 2.99+, MACS3 3.0+. SnapATAC2 2.8+ uses `pp.import_fragments`; older 2.5-2.7 used `pp.import_data` (renamed/removed in 2.9). |
| 4 | |
| 5 | Verify before use: |
| 6 | - Python: `pip show <package>` then `help(module.function)` to check signatures |
| 7 | - R: `packageVersion('<pkg>')` then `?function_name` to verify parameters |
| 8 | - CLI: `<tool> --version` then `<tool> --help` to confirm flags |
| 9 | |
| 10 | If code throws unexpected errors, introspect the installed package and adapt rather than retrying. |
| 11 | |
| 12 | # Single-Cell ATAC-seq |
| 13 | |
| 14 | **"Process my 10X scATAC data from cellranger output"** -> Build a per-cell fragment matrix, compute per-cell QC, dimensionality reduction (TF-IDF + LSI / spectral / autoencoder), cluster, call cluster-level pseudobulk peaks, annotate cell types via gene-activity scores, and integrate with paired scRNA-seq if Multiome. |
| 15 | |
| 16 | - R: `Signac::CreateChromatinAssay()` -> `Seurat` workflow (TF-IDF + SVD + UMAP + Leiden) |
| 17 | - R: `ArchR::createArrowFiles()` -> ArchR project (TileMatrix + LSI + UMAP) |
| 18 | - Python: `snapatac2.pp.import_fragments()` -> SnapATAC2 (spectral / diffusion-map clustering) |
| 19 | - CLI (preprocessing): `cellranger-atac count` (10X) or `chromap` (alignment-only fragment files) |
| 20 | |
| 21 | ## Ecosystem Choice (The Most Important Decision) |
| 22 | |
| 23 | | Ecosystem | Language | Strength | Fails when | Best for | |
| 24 | |-----------|---------|---------|------------|----------| |
| 25 | | Signac (Stuart 2021) | R, Seurat-based | Tightest scRNA-seq integration; Seurat ecosystem mature | Memory hungry on >100K cells; slower than ArchR | Multiome RNA+ATAC; small-to-medium datasets; Seurat user | |
| 26 | | ArchR (Granja 2021) | R, Arrow/HDF5 | Memory-efficient (Arrow files); fast on 100K-1M cells; built-in trajectory + doublet | Less RNA-seq integration; ArchR-specific format | Large bulk-cohort scATAC; trajectory analysis; ATAC-only | |
| 27 | | SnapATAC2 (Zhang 2024) | Python, AnnData | Memory-efficient; modern Python ecosystem; spectral clustering performant | Newer; benchmarks evolving; ecosystem smaller than R | Python-first labs; very large datasets (>1M cells) | |
| 28 | | Cell Ranger ATAC | CLI (10X-specific) | 10X official preprocessing | Closed; fixed pipeline | Only as preprocessing step; analysis happens elsewhere | |
| 29 | | scATAC-pro | CLI-based pipeline | Alternative preprocessing | Less maintained | Legacy; not recommended for new projects | |
| 30 | |
| 31 | Methodology evolves; verify against Granja 2021 (ArchR), Stuart 2021 (Signac), Zhang 2024 (SnapATAC2), Heumos 2023 (best practices) before locking pipelines. |
| 32 | |
| 33 | ## 10X Multiome Caveat (Paired RNA + ATAC) |
| 34 | |
| 35 | 10X Multiome chemistry profiles RNA AND ATAC from the same cell. Outputs are joined by a shared barcode. Multiome workflows use Signac for ATAC and Seurat for RNA, integrated through the same Seurat object via WNN (Weighted Nearest Neighbor; Hao 2021). |
| 36 | |
| 37 | Single-modality 10X scATAC (chemistry v1, v2) does NOT produce paired RNA. Verify the chemistry on the cellranger summary before assuming Multiome. |
| 38 | |
| 39 | ## Per-Cell QC Thresholds |
| 40 | |
| 41 | | Metric | Definition | Pass | Caution | Reject | Source | |
| 42 | |--------|-----------|------|---------|--------|--------| |
| 43 | | Fragment count per cell | n_fragments after dedup | 3000-50000 | 1000-3000 | < 1000 or > 80000 | 10X recommendation; high = doublet | |
| 44 | | TSS enrichment per cell | Signal at TSS / flanks (per cell) | >= 4 | 2-4 | < 2 | ArchR / Signac default; lower than bulk because per-cell | |
| 45 | | Nucleosome signal | Mono / NFR fragment ratio | <= 4 | 4-10 | > 10 | Signac default; high = poor library | |
| 46 | | % reads in peaks (per cell) | FRiP per cell at consensus | >= 0.15 | 0.10-0.15 | < 0.05 | ArchR / Signac defaults | |
| 47 | | Mitochondrial fraction (per cell) | chrM / total per cell | < 0.05 | 0.05-0.15 | > 0.20 | Lower than bulk; per-cell more sensitive | |
| 48 | | Doublet score | AMULET / ArchR doublet | < 0.5 | 0.5-0.7 | > 0.7 | Tool-dependent threshold | |
| 49 | | Blacklist ratio | Reads in ENCODE blacklist / total | < 0.05 | 0.05-0.10 | > 0.10 | Standard | |
| 50 | |
| 51 | Per-cell thresholds are looser than bulk because individual cells have orders of magnitude less signal; the population aggregate is what matters. |
| 52 | |
| 53 | ## Doublet Detection: Three Approaches |
| 54 | |
| 55 | | Tool | Method | Strength | Fails when | |
| 56 | |------|--------|---------|------------| |
| 57 | | AMULET (Thibodeau 2021) | Coll |