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

Important bug fix for ambigous character resolutions #30

Merged
merged 1 commit into from
Oct 26, 2022
Merged

Conversation

spond
Copy link
Member

@spond spond commented Oct 26, 2022

Thanks for Reagan Kelly of the CDC for tracking down this issue.
Starting in version 1.0.8 there was a subtle bug that would manifest if the first ambiguous character in the first sequence being compared fell on an odd (0-based position) in the first half (roughly) of the sequence. This would cause the code to incorrectly skip the pair of nucleotides with the ambiguous base and instead double-count the next pair of characters, so in something like

ambig-bug.fas
....

>Seq1
AAAARCTTTTTTT
>Seq2
AAAAACTTTTTTT

So for example

tn93 -l 5 -q -a average ambig-bug.fas

would return 0 for the distance between Seq1 and Seq2, because instead of comparing the R-A pair, the code would instead compare C-C (the next position)

@spond spond merged commit 03d2484 into master Oct 26, 2022
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.

1 participant