bio-atac-seq-motif-deviation
Version Compatibility
Reference examples tested with: chromVAR 1.24+, motifmatchr 1.24+, JASPAR2024 0.99+, TFBSTools 1.40+, BSgenome.Hsapiens.UCSC.hg38 1.4+, SummarizedExperiment 1.32+, limma 3.58+, ggplot2 3.5+, Matrix 1.6+, ArchR 1.0.2+, Signac 1.13+.
Before using code patterns, verify installed versions match. If versions differ:
- R:
packageVersion('<pkg>')then?function_nameto verify parameters
If code throws unexpected errors, introspect the installed package and adapt rather than retrying.
Motif Deviation (chromVAR)
"Which TF motifs explain accessibility variation across my samples or cells?" -> Compute per-sample (or per-cell) deviation z-scores: how many standard deviations above expectation each TF motif's accessibility falls, controlling for GC content and overall accessibility via matched background peak sets.
- R:
chromVAR::computeDeviations(counts, motifs)-> per-sample z-scores - R:
chromVAR::computeVariability(dev)-> per-motif variance ranking - Single-cell alternative:
Signac::RunChromVAR()(wrapper with matched defaults) orArchR::addDeviationsMatrix()
chromVAR answers a different question than footprinting: footprinting asks "is this specific motif site bound?", chromVAR asks "do peaks containing this motif have systematically more or less accessibility than expected?" The two are complementary.