git://source.jalview.org
/
jalview.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6d2246e
)
JAL-2023 JAL-1681 fixed bug in computing '+' for co-modal codons
author
gmungoc
<g.m.carstairs@dundee.ac.uk>
Wed, 20 Jul 2016 08:05:29 +0000
(09:05 +0100)
committer
gmungoc
<g.m.carstairs@dundee.ac.uk>
Wed, 20 Jul 2016 08:05:29 +0000
(09:05 +0100)
src/jalview/analysis/AAFrequency.java
patch
|
blob
|
history
diff --git
a/src/jalview/analysis/AAFrequency.java
b/src/jalview/analysis/AAFrequency.java
index
3d61b11
..
fb49541
100755
(executable)
--- a/
src/jalview/analysis/AAFrequency.java
+++ b/
src/jalview/analysis/AAFrequency.java
@@
-624,8
+624,11
@@
public class AAFrequency
String modalCodon = String.valueOf(CodingUtils
.decodeCodon(modalCodonEncoded));
if (sortedCodonCounts.length > 1
- && sortedCodonCounts[codons.length - 2] == modalCodonEncoded)
+ && sortedCodonCounts[codons.length - 2] == sortedCodonCounts[codons.length - 1])
{
+ /*
+ * two or more codons share the modal count
+ */
modalCodon = "+";
}
float pid = sortedCodonCounts[sortedCodonCounts.length - 1] * 100