disable automatic filling of 0s in profile#433
Conversation
- functionally working but not correct - pending implementation change for WGS correction
There was a problem hiding this comment.
Pull request overview
This PR adds optional Bayesian smoothing for low-mutation samples when generating mutational profiles, refines omega QC flag annotation, and extends contamination QC with a SNP-site–based metric.
Changes:
- Introduce
profile_smoothingparameter and wire a cohort-level prior profile into profile computation. - Extend
mut_profile.pyto support smoothing via--smoothed/--prior_profileand perform the Bayesian update under a hardcoded (200) mutation threshold. - Refactor omega-flag annotation logic and add an additional contamination QC output based on SNP sites.
Reviewed changes
Copilot reviewed 5 out of 8 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| subworkflows/local/mutationprofile/main.nf | Adds cohort prior computation and passes it into per-sample profile generation when smoothing is enabled. |
| modules/local/compute_profile/main.nf | Extends module inputs to accept a cohort prior profile and conditionally adds CLI args for smoothing. |
| conf/modules.config | Plumbs params.profile_smoothing into COMPUTEPROFILE via ext.smoothing. |
| bin/mut_profile.py | Implements Bayesian smoothing and exposes new CLI flags to apply it. |
| nextflow.config | Adds params.profile_smoothing default. |
| nextflow_schema.json | Exposes profile_smoothing in the schema/UI. |
| bin/check_contamination.py | Refactors contamination entrypoints and adds SNP-based contamination proportion output. |
| bin/annotate_omega_failing.py | Splits flagged tables into gene/sample criteria, updates plots, and changes omega annotation merge logic. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
I focused on the mut_profile.py script and as far as I can tell everything looks correct. I commented on the definition of MUT_PROBABILITY in line 302, we can add a comment here for clarity, as this step is critical. I also suggest to provide this profile in normalized form so that the scale, although arbitrary, always displays the same range of values.
|
we agreed this branch is ready to be merged, only pending to be fully tested with the update that removes the pseudocount of relative mutability per channel once we merge #390 |
Uh oh!
There was an error while loading. Please reload this page.