Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BUG Fix new all zero replace #239

Merged
merged 6 commits into from
Feb 23, 2024
Merged

BUG Fix new all zero replace #239

merged 6 commits into from
Feb 23, 2024

Conversation

BorisMuzellec
Copy link
Collaborator

Reference Issue or PRs

Fixes #237, closes #238

What does your PR implement? Be specific.

This PR fixes a bug arising when all genes whose Cooks outliers are replaced lead to all-zero values (cf #237).

To fix this, it introduces (similarly to DESeq2) a new varm field, "refitted", which complements "replaced" by indicating whether dispersions and LFCs were refitted for that gene (on top of its having values replaced).

Finally, the faulty example presented in #237 was added to the test suite.

Copy link
Collaborator

@umarteauowkin umarteauowkin left a comment

Choose a reason for hiding this comment

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

LGTM, thanks a lot @BorisMuzellec

@BorisMuzellec BorisMuzellec merged commit b202fd8 into main Feb 23, 2024
14 checks passed
@BorisMuzellec BorisMuzellec deleted the fix_new_all_zero_replace branch February 23, 2024 08:42
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.

Why is replacement not done if it would result in all zero counts? [BUG] KeyError in cooks replacement
2 participants