Skip to content

fix: write improved consensus variant table as diagnostic output - #50

Merged
m-jahn merged 5 commits into
mainfrom
dev
Oct 7, 2026
Merged

m-jahn merged 5 commits into
mainfrom
dev

Conversation

@m-jahn

@m-jahn m-jahn commented Oct 5, 2026 •

Copy link
Copy Markdown
Member

@github-actions

github-actions Bot commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor

Super-linter summary

Language Validation result
SNAKEMAKE_SNAKEFMT Pass ✅
YAML_PRETTIER Pass ✅

All files and directories linted successfully

For more information, see the GitHub Actions workflow run

Powered by Super-linter

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟡 Changes recommended

A few issues in the updated workflow/report code (misleading consensus file extension, doc path mismatch, unused sample-sheet read, and lingering rowwise grouping) should be fixed to avoid confusion and potential downstream problems.

Review effort: Lite
Findings: 2 Medium severity · 2 Low severity

Open (4)
What changed in this PR

This PR improves the “consensus variants” diagnostic output used by the report by capturing bcftools isec metadata and expanding the consensus presence/absence encoding into a more user-friendly table (with per-sample columns and variant annotations), addressing the sample-order mismatch described in #51 and the poor formatting in #48.

Changes:

  • Update the bcftools intersection rule to use bcftools isec -p output directory artifacts (including README.txt) and wire them into the report inputs.
  • Extend the R Markdown report to parse the consensus index, expand the appearance bitstring into named sample columns, annotate variants, and export a TSV alongside the HTML report.
  • Minor refactors in report.Rmd (chunk options placement, formatting, and join scope tightening).
File Description
workflow/​rules/​report.smk Switch intersection output handling to directory-based isec outputs and pass README.txt into the report step.
workflow/​notebooks/​report.Rmd Build a richer consensus variant table (sample-named columns + annotations) and write it as a TSV diagnostic output.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread workflow/notebooks/report.Rmd Outdated
Comment thread workflow/rules/report.smk
Comment thread workflow/notebooks/report.Rmd
Comment thread workflow/notebooks/report.Rmd Outdated
@m-jahn
m-jahn requested a review from rabioinf October 6, 2026 12:38

@rabioinf rabioinf left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good!

@m-jahn
m-jahn merged commit 24f7456 into main Oct 7, 2026
6 checks passed
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.

bcftools intersection has mixed up sample input compared to report print better formatted table for the consensus variants

3 participants