feat: allow snp_allele_frequencies to accept genomic regions#1076
Open
joshitha1808 wants to merge 2 commits intomalariagen:masterfrom
Open
feat: allow snp_allele_frequencies to accept genomic regions#1076joshitha1808 wants to merge 2 commits intomalariagen:masterfrom
joshitha1808 wants to merge 2 commits intomalariagen:masterfrom
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What problem does this solve:
Previously,
snp_allele_frequencies()required a transcript as input. This meant analyses were limited to coding regions, and users couldn’t easily check SNP allele frequencies for arbitrary genomic regions.How does it solve it:
This PR adds an optional
regionparameter, so users can now specify any genomic region directly. The function will accept either a transcript or a region .When a region is used, SNP calls and allele frequencies are calculated for that region. Effect annotations are still only generated if a transcript is provided. Plot titles are automatically adjusted to work with both transcript- and region-based queries.Issue number:
Closes #805
Testing done:
Added unit tests for region-based queries.
Verified that all existing transcript-based tests still pass.
Confirmed that effect annotations are applied correctly when using transcripts.
Breaking changes or migration notes:
No.