* Used by getRNASecStrucState
*
*/
- public static Hashtable toRNAssState;
+ public static Hashtable<String, String> toRNAssState;
+
+ public static boolean RNAcloseParen[] = new boolean[255];
static
{
toRNAssState = new Hashtable<String, String>();
toRNAssState.put("y", "Y");
toRNAssState.put("Z", "Z");
toRNAssState.put("z", "Z");
-
+ for (int p = 0; p < RNAcloseParen.length; p++)
+ {
+ RNAcloseParen[p] = false;
+ }
+ for (String k : toRNAssState.keySet())
+ {
+ RNAcloseParen[k.charAt(0)] = k.charAt(0) != toRNAssState.get(k)
+ .charAt(0);
+ }
}
/**
String ssc = ssstring.substring(i, i + 1);
if (toRNAssState.containsKey(ssc))
{
- ss.append((String) toRNAssState.get(ssc));
+ // valid ss character - so return it
+ ss.append(ssc); // (String) toRNAssState.get(ssc));
}
else
{
return ss.toString();
}
+ public static boolean isCloseParenRNA(char dc)
+ {
+ return RNAcloseParen[dc];
+ }
+
// main method generates perl representation of residue property hash
// / cut here
public static void main(String[] args)