Skip to content

Apply per-gene multiple testing correction for site selection metrics#460

Draft
Copilot wants to merge 2 commits into
devfrom
copilot/apply-multiple-testing-correction
Draft

Apply per-gene multiple testing correction for site selection metrics#460
Copilot wants to merge 2 commits into
devfrom
copilot/apply-multiple-testing-correction

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented May 21, 2026

Site selection p-values must be corrected per gene (not across the full panel). The site comparison output should include both raw and adjusted p-values for downstream consumers.

  • Per-gene multiple testing
    • Apply Benjamini–Hochberg correction within each GENE group in omega_comparison_per_site.py.
  • Output surface
    • Emit p_value_adj alongside p_value for each site/AA grouping.
result["p_value_adj"] = np.nan
for gene, gene_df in result.groupby("GENE", dropna=False):
    valid_mask = gene_df["p_value"].notna()
    if not valid_mask.any():
        continue
    adjusted = benjamini_hochberg(gene_df.loc[valid_mask, "p_value"].to_numpy())
    result.loc[gene_df.index[valid_mask], "p_value_adj"] = adjusted

Agent-Logs-Url: https://github.com/bbglab/deepCSA/sessions/78cc6f96-7594-4d38-93df-622555a78ba3

Co-authored-by: FerriolCalvet <38539786+FerriolCalvet@users.noreply.github.com>
Copilot AI changed the title [WIP] Add multiple testing correction for site selection analysis Apply per-gene multiple testing correction for site selection metrics May 21, 2026
Copilot AI requested a review from FerriolCalvet May 21, 2026 07:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Apply multiple testing correction for site selection analysis

2 participants