JAL-2629 fix issue where HMM sequence would be longer than alignment
authorTZVanaalten <TZVanaalten@LS30916.ad.lifesci.dundee.ac.uk>
Wed, 30 Aug 2017 16:42:13 +0000 (17:42 +0100)
committerTZVanaalten <TZVanaalten@LS30916.ad.lifesci.dundee.ac.uk>
Wed, 30 Aug 2017 16:42:13 +0000 (17:42 +0100)
src/jalview/hmmer/HMMBuildThread.java

index 2ff89c1..f940fbb 100644 (file)
@@ -372,7 +372,7 @@ public class HMMBuildThread implements Runnable
     {
       seq.insertCharAt(0, group.getStartRes(), '-');
       seq.insertCharAt(group.getEndRes() + 1,
-              alignment.getWidth() - group.getEndRes(), '-');
+              alignment.getWidth() - group.getEndRes() - 1, '-');
       seq.updateHMMMapping();
       SequenceI topSeq = group.getSequencesInOrder(alignment)[0];
       int topIndex = alignment.findIndex(topSeq);