wjwei-handsome / wgatools

Whole Genome Alignment Tools
MIT License
113 stars 7 forks source link

maf-index error: Different order between records #17

Open sivico26 opened 5 days ago

sivico26 commented 5 days ago

Hi,

Thanks for developing wgatools, it looks very promising.

I am particularly interested in visualizing some .maf files that I generated by progressive alignment with cactus, and then converting to .maf with cactus-hal2maf.

When I try to index the resulting files I get the following:

$ wgatools maf-index reg11_nobav.maf 
2024-10-14T15:23:16.139440118+02:00 ERROR There is a different order between Records!

Even though the message sounds simple enough, I am unsure what exactly the problem is or how to address it. Can I ask you to elaborate on this one?

Here is one of my input files: reg11_nobav.maf.txt

Thank you in advance for your help.

wjwei-handsome commented 2 days ago

Hi @sivico26, sorry for the late reply.

The reason for this error is:

The species order in a maf file should be fixed, such as:

a ...
b ...
c ...

a ...
b ...
c ...

BUT NOT:

a ...
b ...
c ...

a ...
c ...
b ...

In your provided file, I found a strange block in L5062-L5070, looks like:

   s       ref.Cexcelsa_scaf_4:10496403-10611174   112460  1       +       114771  A
   s       cdan.cdan       98736   1       +       104684  C
   s       cgro6.cgro6     104117  1       +       115507  C
   s       cgro7.cgro7     92928   1       +       100827  C
   s       coff.coff       92012   1       +       101072  A
   s       cpol.cpol       108588  1       +       112818  A
   s       ctat.ctat       93892   1       +       102711  A

The number of species in this block is not equal to your all species. Please check!

If you need further help, please let me know :)

Best, Wenjie