Skip to main content
Alpha Cyanea is in public alpha. We're building in the open — expect rough edges and rapid iteration. See what's live

cyanea-epi

v0.1.1 Analysis

Peaks, motifs, and chromatin states from ChIP-seq and ATAC-seq.

Analysis layer Apache-2.0 8 functions

Epigenomics — MACS2-style peak calling, motif discovery, chromatin state modeling, differential binding, and ATAC-seq QC.

Overview

cyanea-epi analyzes chromatin data from ChIP-seq, ATAC-seq, and related assays. It calls peaks, builds coverage pileups, discovers and scans sequence motifs, models chromatin states, tests differential binding, and reports the QC metrics reviewers expect.

Key Concepts

Peak Calling

Enriched regions are identified by comparing treatment signal against a control (or a local background model), following the MACS2 approach. Narrow mode targets sharp transcription-factor binding sites; broad mode captures diffuse histone-mark domains.

Motifs

De novo discovery finds recurring sequence patterns in peak regions and expresses them as position weight matrices. scan_pwm then scores arbitrary sequences against a PWM, and MEME-format import/export interoperates with existing motif databases.

Chromatin States

A ChromHMM-style hidden Markov model learns recurrent combinations of histone marks and segments the genome into interpretable states (promoter, enhancer, quiescent, and so on).

QC

TSS enrichment and fraction-of-reads-in-peaks (FRiP) are the headline quality metrics for ATAC-seq and are computed directly from reads and peak calls.

Code Examples

Rust

use cyanea_epi::{call_peaks, PeakMode, tss_enrichment};

let peaks = call_peaks(&treatment, &control, PeakMode::Narrow);
let tss = tss_enrichment(&reads, &tss_sites);

JavaScript (WASM)

import { scan_pwm, frip } from '/wasm/cyanea_wasm.js';

const hits = JSON.parse(scan_pwm(sequence, JSON.stringify(pwm), 0.8));
const score = frip(JSON.stringify(reads), JSON.stringify(peaks));

Use Cases

  • ChIP-seq — Call binding sites and test differential binding between conditions.
  • ATAC-seq — Assess library quality with TSS enrichment and FRiP, then call accessible regions.
  • Regulatory genomics — Discover motifs and annotate chromatin states genome-wide.

API Surface

call_peaks (treatment, control, mode) -> JSON MACS2-style narrow/broad peak calling
pileup (reads, extend) -> JSON Fragment pileup and coverage track
discover_motifs (sequences: &str) -> JSON De novo motif discovery with PWM output
scan_pwm (seq, pwm, threshold) -> JSON Score a sequence against a position weight matrix
chromhmm_states (marks: &str, n_states) -> JSON Learn and assign chromatin states
differential_binding (a, b) -> JSON DESeq2-style differential binding analysis
tss_enrichment (reads, tss) -> f64 ATAC-seq TSS enrichment score
frip (reads, peaks) -> f64 Fraction of reads in peaks

Depended on by

Tags

Epigenomics ChIP-seq ATAC-seq Peaks Motifs