From 0ae0539d4fc9e78d94c33afe0ac07457464afd16 Mon Sep 17 00:00:00 2001 From: Jim Procter Date: Mon, 17 Jun 2013 17:41:40 +0100 Subject: [PATCH] JAL-1027 use alternative codon table in ResidueProperties.codonHash2 for translation --- src/jalview/schemes/ResidueProperties.java | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/src/jalview/schemes/ResidueProperties.java b/src/jalview/schemes/ResidueProperties.java index a5c4e84..62e46be 100755 --- a/src/jalview/schemes/ResidueProperties.java +++ b/src/jalview/schemes/ResidueProperties.java @@ -1485,6 +1485,19 @@ public class ResidueProperties public static String codonTranslate(String lccodon) { + if (false) + { + return _codonTranslate(lccodon); + } + String cdn = codonHash2.get(lccodon.toUpperCase()); + if (cdn!=null && cdn.equals("*")) + { + return "STOP"; + } + return cdn; + } + public static String _codonTranslate(String lccodon) + { String codon = lccodon.toUpperCase(); // all base ambiguity codes yield an 'X' amino acid residue if (codon.indexOf('X') > -1 || codon.indexOf('N') > -1) -- 1.7.10.2