v2 methylation control QC (WIP): simurg methyl qc|convert-manifest (MET-001..018)

Methylation CSV manifest reader (MET-002/003), raw M/U assembly with bead masking
(MET-005), pOOBAH detection p-values, noob background correction, linear/nonlinear dye
bias, beta and M-values (MET-010..012), the 21 methylation control metrics (MET-006,
bs-conv red-bg set option), per-sample ctrl/cgs tables, summary tsv/xlsx/html with the
detection histogram and a beta PCA, pcs.tsv.gz, controls_raw/controls_qc.tsv; methylation
datasets load in qc report (MET-014); qc controls --array-type methylation; minfi-style
Sentrix_ID/Sentrix_Position sheet keys. Vendor EPIC manifests carry a 5th field on some
control lines: >= 4 fields accepted. Runs on the public minfiDataEPIC set (3 x NA12878).
This commit is contained in:
kemal committed 2026-09-29 00:13:22 +01:00
1 parent d235dc5419
commit 3eb51639cc
13 files changed
+1292 -21

No files matched your search

+3 -4
View File
@@ -167,10 +167,9 @@ def test_absent_addresses_are_skipped() -> None: # QC-008, K-021: two bead-pool
assert q.missing["staining_green"] == ["biotin_bkg"]
def test_methylation_is_v2() -> None:
with pytest.raises(SimurgError) as e:
compute_control_metrics(_beads(), np.ones(21), np.ones(21), "methylation")
assert e.value.code == "E_QC_METHYLATION"
def test_methylation_metric_set() -> None: # QC-006: methylation metrics are computed (v2); missing ones are NaN
q = compute_control_metrics(_beads(), np.ones(21), np.ones(21), "methylation")
assert len(q.values) == 21 and "stringency" not in q.values and "bs_conv_2" in q.missing
# ------------------------------------------------------------------------------------------------ thresholds