X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=src%2Fjalview%2Fschemes%2FResidueProperties.java;h=593e83db10bbd1eefe0a75b1fbd4c8012aeb4811;hb=ad15cff29620f960119f80176f1fd443da9f6763;hp=aca75b742694e8ae6fc665cdf29e049e0ed174a3;hpb=f6483e3414133aeadc65a9fb24f1b81cbbf3f39f;p=jalview.git diff --git a/src/jalview/schemes/ResidueProperties.java b/src/jalview/schemes/ResidueProperties.java index aca75b7..593e83d 100755 --- a/src/jalview/schemes/ResidueProperties.java +++ b/src/jalview/schemes/ResidueProperties.java @@ -1,6 +1,6 @@ /* - * Jalview - A Sequence Alignment Editor and Viewer (Version 2.8.2) - * Copyright (C) 2014 The Jalview Authors + * Jalview - A Sequence Alignment Editor and Viewer ($$Version-Rel$$) + * Copyright (C) $$Year-Rel$$ The Jalview Authors * * This file is part of Jalview. * @@ -20,6 +20,7 @@ */ package jalview.schemes; +import jalview.analysis.scoremodels.FeatureScoreModel; import jalview.analysis.scoremodels.PIDScoreModel; import jalview.api.analysis.ScoreModelI; @@ -1498,6 +1499,7 @@ public class ResidueProperties // scoreMatrices.put("Conservation EnhPos", new // ScoreMatrix("Conservation EnhPos",propMatrixEpos,0)); scoreMatrices.put("PID", new PIDScoreModel()); + scoreMatrices.put("Displayed Features", new FeatureScoreModel()); } private ResidueProperties() @@ -1699,7 +1701,9 @@ public class ResidueProperties * Used by getRNASecStrucState * */ - public static Hashtable toRNAssState; + public static Hashtable toRNAssState; + + public static boolean RNAcloseParen[] = new boolean[255]; static { toRNAssState = new Hashtable(); @@ -1763,7 +1767,15 @@ public class ResidueProperties 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); + } } /** @@ -1784,7 +1796,8 @@ public class ResidueProperties 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 { @@ -1794,6 +1807,11 @@ public class ResidueProperties 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)