Problem of unitig position shift in query results
Opened this issue · 0 comments
hl-xue commented
Hi @kamimrcht,
Here is the problem I met during Reindeer query:
>AC004707.1-ENST00000511627.contig1 0-54:5,55-66:*,...,429-480:74,481-578:*,579-593:4,594-581:*
The problem occurs at the last triplet, where the starting position 594 is larger than ending position 581.
Also, I summarized the problem met by Chloé:
unitig0 (1 k-mer): position 0-0 should be 0-0 (OK)
unitig1 (1 k-mers): position 1-2 should be 1-1
unitig2 (4 k-mers): position 3-7 should be 2-5
unitig3 (21 k-mers): position 8-29 should be 6-26
unitig4 (2 k-mers): position 30-32 should be 27-28
It seems for the unitig_i (i > 0), the starting position is shifted by (i - 1), and the ending position is shifted by i.
I imagine there is a potential bug when calculating the end position of unitig, it should be pos.start + nb.kmer - 1
instead of pos.start + nb.kmer
. But I don't know why the unitig0's result is correct.
Thanks !