{\r
\r
Hashtable residueHash = new Hashtable();\r
- int maxCount = -1;\r
+ int maxCount = 0;\r
String maxResidue = "-";\r
int nongap = 0;\r
for (int j=0; j < sequences.size(); j++)\r
if (s.getSequence().length() > i)\r
{\r
\r
- String res = s.getSequence().substring(i,i+1);\r
+ String res = s.getSequence().charAt(i)+"";\r
\r
- if (!res.equals("-"))\r
+ if (!jalview.util.Comparison.isGap(res.charAt(0)))\r
nongap++;\r
\r
if (residueHash.containsKey(res))\r
int count = ((Integer)residueHash.get(res)).intValue() ;\r
count++;\r
\r
- if (!res.equals("-") && count >= maxCount)\r
+ if (!jalview.util.Comparison.isGap(res.charAt(0)) && count >= maxCount)\r
{\r
\r
if(count>maxCount)\r
}\r
}\r
}\r
+\r
residueHash.put("maxCount",new Integer(maxCount));\r
+ if(maxCount<0)\r
+ System.out.println("asasa "+maxCount);\r
residueHash.put("maxResidue", maxResidue);\r
residueHash.put("size", new Integer(sequences.size()));\r
residueHash.put("nongap", new Integer(nongap));\r