Skip to content

major changes to the report style#21

Merged
ypriverol merged 4 commits intomainfrom
dev
Mar 19, 2026
Merged

major changes to the report style#21
ypriverol merged 4 commits intomainfrom
dev

Conversation

@ypriverol
Copy link
Contributor

@ypriverol ypriverol commented Mar 19, 2026

Summary by CodeRabbit

  • New Features

    • New CLI flag to control two-sided QC plot layout.
    • Standalone "Sample Completeness" and "Missing Frequency" visualizations.
  • Improvements

    • Restructured QC report: updated completeness metrics, revised plot titles, and simplified summary table logic.
    • Missing-data block now shown only when LOD information is absent; some QC summary rows simplified.
  • Tests

    • Updated HTML test expectations to reflect renamed summary fields.

@coderabbitai
Copy link

coderabbitai bot commented Mar 19, 2026

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: eb44e732-cf70-4825-9d04-b17d592aa6b7

📥 Commits

Reviewing files that changed from the base of the PR and between 97a5b89 and 0e77a23.

📒 Files selected for processing (1)
  • tests/test_qc_pipeline.py

📝 Walkthrough

Walkthrough

Adds a CLI flag --two-sides/--no-two-sides and threads it into report generation; introduces two standalone QC visualizers (sample completeness and missing-frequency); updates labels and rewires split-report generation to optionally produce deferred side-by-side HTML pages and adjust summary table content.

Changes

Cohort / File(s) Summary
CLI Option Threading
src/pyprideap/cli.py
Added --two-sides/--no-two-sides option (default on) and two_sides: bool = True parameter to _generate_report/report, passed to qc_report_split.
Data Label Update
src/pyprideap/viz/qc/compute.py
Changed DataCompletenessData.title default from "Data Completeness" to "Sample Completeness".
New Renderers
src/pyprideap/viz/qc/render.py
Added render_sample_completeness() and render_missing_frequency(); adjusted subplot titles in existing render_data_completeness().
Report Split & Summary Logic
src/pyprideap/viz/qc/report.py
Added two_sides: bool = True to qc_report_split; introduced _DATA_KEY_MAP, replaced data_completeness with two new sections, deferred side-by-side plot generation when two_sides set, simplified summary table rows/logic.
Tests
tests/test_qc_pipeline.py
Updated assertions to expect "Features (assays)" in dataset summary table instead of "Detection rate".

Sequence Diagram(s)

sequenceDiagram
    participant User as CLI User
    participant CLI as cli.py
    participant Gen as _generate_report()
    participant Split as qc_report_split()
    participant Render as Plot Renderer
    participant HTML as HTML Output

    User->>CLI: run `report --two-sides` (or default)
    CLI->>Gen: call with two_sides=True
    Gen->>Split: qc_report_split(..., two_sides=True)
    
    rect rgba(100,150,200,0.5)
    Split->>Render: render plots (sample_completeness, missing_frequency, other QC plots)
    end
    
    alt two_sides=True
        Split->>HTML: defer complementary plots and compose side-by-side pages
    else two_sides=False
        Split->>HTML: emit individual plot pages/fragments
    end

    HTML-->>User: deliver report (layout varies by two_sides)
Loading

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~45 minutes

Possibly related PRs

Suggested reviewers

  • selvaebi
  • chakrabandla

Poem

🐰 Two-sided plots hop into view,
Bars stack high on samples true,
Missing beats in histogram light,
Reports split neat — a bunny's delight! ✨

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 inconclusive)

Check name Status Explanation Resolution
Title check ❓ Inconclusive The title 'major changes to the report style' is vague and generic, using non-descriptive language that doesn't convey the specific nature of the changes. Consider a more specific title that highlights key changes, such as 'Add two-sides layout option for QC reports and refactor data completeness visualizations' or 'Restructure QC report rendering with sample completeness charts and configurable layout'.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Docstring Coverage ✅ Passed Docstring coverage is 88.89% which is sufficient. The required threshold is 80.00%.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch dev
📝 Coding Plan
  • Generate coding plan for human review comments

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@ypriverol ypriverol merged commit d335877 into main Mar 19, 2026
12 checks passed
@coderabbitai coderabbitai bot mentioned this pull request Mar 19, 2026
Merged
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.

1 participant