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

todo: Improve --regions-overlap variant #1746

Open
pd3 opened this issue Feb 9, 2024 · 0 comments
Open

todo: Improve --regions-overlap variant #1746

pd3 opened this issue Feb 9, 2024 · 0 comments

Comments

@pd3
Copy link
Member

pd3 commented Feb 9, 2024

The mode --regions-overlap variant|2 is supposed to recognize the actual bases affected by the variant. This is trickier than currently implemented in https://github.com/samtools/htslib/blob/develop/synced_bcf_reader.c#L569.

The existing code trims variants from the left, but does not take into account cases like ACGA > A--A, which can be trimmed from both ends.

In addition, the API does not give the choice to trim from the left or right in ambiguous cases. For many use cases, the desired behavior is to trim in such a way to prevent spurious overlaps. Alternatively, a new mode 3 can be added which acts the opposite way and reports an overlap whenever possible.

pd3 added a commit to samtools/bcftools that referenced this issue Feb 12, 2024
Add new --regions-overlap option which allows to take into account overlapping deletions
that start out of the fasta file target region.

Note this will need to be updated if the issue samtools/htslib#1746
is resolved.

Resolves #2091
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

No branches or pull requests

1 participant