Entering edit mode
6.4 years ago
BDK_compbio
▴
140
I am using edlib library for sequence alignment using edit (Levenshtein) distance. It says that its infix(HW) alignment method does not penalize the start and end gaps. But it does not output the correct result when I use HW mode.
#include <cstdio>
#include "edlib.h"
int main() {
EdlibAlignResult result = edlibAlign("hello world", 11, "world!", 6, edlibNewAlignConfig(-1, EDLIB_MODE_HW, EDLIB_TASK_PATH, NULL, 0));
if (result.status == EDLIB_STATUS_OK) {
printf("edit_distance('hello world', 'world!') = %d\n", result.editDistance);
}
edlibFreeAlignResult(result); }
The edit distance should be zero, but it returns 5. I am wondering if I am missing something.