bobeobibo / phigaro

Phigaro is a scalable command-line tool for predicting phages and prophages
MIT License
46 stars 15 forks source link

Output coordinates are off by 1 #35

Closed snystrom closed 5 months ago

snystrom commented 2 years ago

Hi,

Thanks for the great tool. I noticed a minor bug in the gff3 and bed outputs where the start positions of genes are shifted 1 bp downstream. See example image below (expected start codon is AUG at this locus).

image

I may be able to push a fix for this soon, but wanted to get your thoughts on implementation. It looks like the software in batch/task/run_phigaro.py is doing the correct math assuming 0-based indexing, so the input data must actually be 1-based coming out of find_phages? I guess there's 2 possible fixes: 1. alter find_phages behavior, or 2. adjust the coordinate shifting math in run_phigaro.py. I'm assuming fixing the shifting math is easier, but I wonder if there are other places in the codebase that make the 0-based indexing assumption.

Cheers, -Spencer

PollyTikhonova commented 2 years ago

Thanks for your contribution! we'll deal with it!

PollyTikhonova commented 5 months ago

I am happy to announce that this issue was fixed in phigaro 2.4.0