Computational Genomics Foundations

Deep Dives

Rigorous, first-principles, and interactive explorations of essential computational genomics concepts, statistical genetics, DNA sequence foundation models, and biological algorithms.

Statistical & Population GeneticsPolygenic Architecture & Trait MappingFoundational to Advanced18 min read

Genome-Wide Association Studies (GWAS): The Mathematical Engine of Trait Mapping

A first-principles, rigorous journey through Genome-Wide Association Studies (GWAS) — from genotype dosage matrices and OLS regression to ancestry PCA confounding ("the chopsticks problem"), Linkage Disequilibrium (LD), Manhattan skyscraper plots, and Polygenic Risk Scores (PRS).

  • Additive genotype dosage matrix G ∈ {0,1,2}^(N×M) and OLS/LMM Wald test derivations
  • The chopsticks problem: ancestry confounding, EIGENSTRAT PCA & λ_GC inflation factor
  • Linkage Disequilibrium blocks (r², D'), recombination hotspots & statistical fine-mapping
  • Bonferroni threshold derivation (p < 5×10⁻⁸), Fisher’s infinitesimal vs Boyle-Li-Pritchard omnigenic models & PRS
Key Formulations:y=α+xjβj+Zγ+ϵy = \alpha + x_j \beta_j + Z\gamma + \epsilontj=β^j/SE(β^j)t_j = \hat{\beta}_j / \text{SE}(\hat{\beta}_j)λGC=median(χobs2)/0.456\lambda_{GC} = \text{median}(\chi^2_{\text{obs}}) / 0.456PRSi=β^jGij\text{PRS}_i = \sum \hat{\beta}_j G_{ij}
Deep Learning in GenomicsTransformers & State Space ModelsAdvanced16 min read

DNA Language Models & Genomic Foundation Architectures

Understanding self-attention, Hyena/Mamba state-space architectures, and masked nucleotide modeling across gigabase mammalian genomes. How tokenization (k-mers vs BPE vs single-base) impacts variant effect prediction.

  • Context scaling: from BERT 512-nt windows to 1M-nt long-range chromosomal models
  • Zero-shot variant pathogenicity scoring via masked token log-likelihood ratios
  • Comparing Enformer, Nucleotide Transformer, HyenaDNA, and Caduceus
Key Formulations:Attention(Q,K,V)=softmax(QKT/dk)V\text{Attention}(Q, K, V) = \text{softmax}(QK^T / \sqrt{d_k}) VLLR(v)=logP(altc)logP(refc)\text{LLR}(v) = \log P(\text{alt} \mid c) - \log P(\text{ref} \mid c)
Coming Soon
Gene Regulation & RNA BiologySplice Junction RecognitionIntermediate to Advanced15 min read

The Neural Splicing Code: Spliceosome Biophysics & Deep Splicing Predictors

How deep convolutional and dilated residual networks decode 5’ donor (GT), 3’ acceptor (AG), and branchpoint consensus sequences. Exploring OpenSpliceAI, Splam, and in silico mutagenesis (ISM) perturbation matrices.

  • Biophysical splicing signals: U1/U2 snRNA base-pairing & polypyrimidine tracts
  • Dilated convolutions capturing 10,000-bp flanking intronic splicing enhancers/silencers
  • Evaluating non-coding cryptic splice activation and exon skipping mutations
Key Formulations:ΔScore=Pmut(Splice)Pref(Splice)\Delta\text{Score} = P_{\text{mut}}(\text{Splice}) - P_{\text{ref}}(\text{Splice})ISM(p,b)=P(Mutpb)P(WT)\text{ISM}(p, b) = P(\text{Mut}_{p \to b}) - P(\text{WT})
Coming Soon
Pangenomics & Graph IndexingGraph Indexing & BWTAdvanced17 min read

Pangenomics, Variation Graphs & Wheeler Coordinate Systems

Generalizing linear Burrows-Wheeler Transforms to pangenome variation graphs. Exploring Wheeler graph conditions, co-lexicographic node orderings, and sublinear path search across polymorphic genomes.

  • Overcoming reference bias: moving from single GRCh38/CHM13 coordinates to rGFA topologies
  • Formal Wheeler graph axioms: co-lexicographic ordering preserving incoming edge labels
  • GBZ, r-index, and PanVC pangenome index querying complexity
Key Formulations:u<v    u<vu < v \implies u' < v'Query Time: O(PlogΣ)\text{Query Time: } \mathcal{O}(P \cdot \log \Sigma)
Coming Soon