double[] stateTransitions;
//annotations
- Integer alignmentColumn = null;
+ int residueNumber;
char consensusResidue;
char referenceAnnotation;
char maskValue;
return matchEmissions;
}
- public double getMatchEmission(int symbolIndex)
+ double getMatchEmission(int symbolIndex)
{
return matchEmissions[symbolIndex];
}
return insertEmissions;
}
- public double getInsertEmission(int symbolIndex)
+ double getInsertEmission(int symbolIndex)
{
return insertEmissions[symbolIndex];
}
return stateTransitions;
}
- public double getStateTransition(int transition)
+ double getStateTransition(int transition)
{
return stateTransitions[transition];
}
this.stateTransitions = stateTransitionsM;
}
- public Integer getAlignmentColumn()
+ int getResidueNumber()
{
- return alignmentColumn;
+ return residueNumber;
}
- public void setAlignmentColumn(int alignmentColumn)
+ public void setResidueNumber(int resNo)
{
- this.alignmentColumn = alignmentColumn;
+ this.residueNumber = resNo;
}
- public char getConsensusResidue()
+
+ char getConsensusResidue()
{
return consensusResidue;
}
{
this.consensusResidue = consensusResidue;
}
- public char getReferenceAnnotation()
+
+ char getReferenceAnnotation()
{
return referenceAnnotation;
}
{
this.referenceAnnotation = referenceAnnotation;
}
- public char getMaskValue()
+
+ char getMaskValue()
{
return maskValue;
}
{
this.maskValue = maskValue;
}
- public char getConsensusStructure()
+
+ char getConsensusStructure()
{
return consensusStructure;
}
{
this.consensusStructure = consensusStructure;
}
+
+ /**
+ * Answers the symbol index of the symbol with the highest match emission
+ * probability (first symbol in case of a tie). Note this object stores
+ * probabilities, not the negative logarithms as in the HMM file.
+ *
+ * @return
+ */
+ int getMaxMatchEmissionIndex()
+ {
+ int maxIndex = 0;
+ double max = 0D;
+
+ for (int i = 0; i < matchEmissions.length; i++)
+ {
+ if (matchEmissions[i] > max)
+ {
+ max = matchEmissions[i];
+ maxIndex = i;
+ }
+ }
+ return maxIndex;
+ }
}