}
for (int i = iStart; i < width; i++)
{
- if (i >= hconsensus.length)
+ Hashtable hci;
+ if (i >= hconsensus.length || ((hci=hconsensus[i])==null))
{
// happens if sequences calculated over were shorter than alignment
// width
continue;
}
value = 0;
+ Float fv;
if (ignoreGapsInConsensusCalculation)
{
- value = ((Float) hconsensus[i].get(StructureFrequency.PID_NOGAPS))
- .floatValue();
+ fv =(Float) hci.get(StructureFrequency.PID_NOGAPS);
}
else
{
- value = ((Float) hconsensus[i].get(StructureFrequency.PID_GAPS))
- .floatValue();
+ fv = (Float) hci.get(StructureFrequency.PID_GAPS);
}
-
- String maxRes = hconsensus[i].get(StructureFrequency.MAXRESIDUE)
+ if (fv==null)
+ {
+ consensus.annotations[i] = null;
+ // data has changed below us .. give up and
+ continue;
+ }
+ value = fv.floatValue();
+ String maxRes = hci.get(StructureFrequency.MAXRESIDUE)
.toString();
- String mouseOver = hconsensus[i].get(StructureFrequency.MAXRESIDUE)
+ String mouseOver = hci.get(StructureFrequency.MAXRESIDUE)
+ " ";
if (maxRes.length() > 1)
{
mouseOver = "[" + maxRes + "] ";
maxRes = "+";
}
- int[][] profile = (int[][]) hconsensus[i]
+ int[][] profile = (int[][]) hci
.get(StructureFrequency.PROFILE);
- int[][] pairs = (int[][]) hconsensus[i]
+ int[][] pairs = (int[][]) hci
.get(StructureFrequency.PAIRPROFILE);
if (pairs != null && includeAllConsSymbols) // Just responsible for the