nathanweeks / exonerate

A fork of exonerate: a generic tool for sequence alignment
GNU General Public License v3.0
61 stars 25 forks source link

Fix for alignment view #29

Closed lgretton closed 11 months ago

lgretton commented 11 months ago

Added an offset of +2 to apos->query_pos to correct an error in the alignment view.

In alignment view, the target value is off by two for all but the last row of the display.

exonerate --alignmentwidth 46 unknown.seq P04247.fasta
Command line: [exonerate --alignmentwidth 46 /home/l/ljg2/unknown.seq /home/l/ljg2/P04247.fasta]
Hostname: [spectre11]

C4 Alignment:
------------
         Query: unknown
        Target: sp|P04247|MYG_MOUSE Myoglobin OS=Mus musculus GN=Mb PE=1 SV=3
         Model: ungapped:dna2protein
     Raw score: 171
   Query range: 128 -> 224
  Target range: 0 -> 32

 129 : atggggctcagtgatggggagtggcagctg : 156
       MetGlyLeuSerAspGlyGluTrpGlnLeu
       ||||||||||||||||||||||||||||||
   1 : MetGlyLeuSerAspGlyGluTrpGlnLeu :  10

 157 : gtgctgaatgtctgggggaaggtggaggcc : 186
       ValLeuAsnValTrpGlyLysValGluAla
       ||||||||||||||||||||||||||||||
  11 : ValLeuAsnValTrpGlyLysValGluAla :  20

 187 : gaccttgctggccatggacaggaagtcctc : 216
       AspLeuAlaGlyHisGlyGlnGluValLeu
       ||||||||||||||||||||||||||||||
  21 : AspLeuAlaGlyHisGlyGlnGluValLeu :  30

 217 : atcggg : 224
       IleGly
       ||||||
  31 : IleGly :  32

vulgar: unknown 128 224 + sp|P04247|MYG_MOUSE 0 32 . 171 M 96 32
-- completed exonerate analysis

It should be as so, differences are highlighted.

129 : atggggctcagtgatggggagtggcagctg : 158 MetGlyLeuSerAspGlyGluTrpGlnLeu |||||||||||||||||||||||||||||| 1 : MetGlyLeuSerAspGlyGluTrpGlnLeu : 10

159 : gtgctgaatgtctgggggaaggtggaggcc : 188 ValLeuAsnValTrpGlyLysValGluAla |||||||||||||||||||||||||||||| 11 : ValLeuAsnValTrpGlyLysValGluAla : 20

189 : gaccttgctggccatggacaggaagtcctc : 218 AspLeuAlaGlyHisGlyGlnGluValLeu |||||||||||||||||||||||||||||| 21 : AspLeuAlaGlyHisGlyGlnGluValLeu : 30

219 : atcggg : 224 IleGly |||||| 31 : IleGly : 32

lgretton commented 11 months ago

Withdrawn, doesn't fix the alignment view for the example provided.