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:
4a6e033
)
JAL-4019 corrected to '>' to '>=' for percentage comparisons
bug/JAL-4125_flatlaf_quithandler_external_structureviewers_not_closed
author
Ben Soares
<b.soares@dundee.ac.uk>
Thu, 22 Jun 2023 13:35:12 +0000
(14:35 +0100)
committer
Ben Soares
<b.soares@dundee.ac.uk>
Thu, 22 Jun 2023 13:35:12 +0000
(14:35 +0100)
src/jalview/util/Comparison.java
patch
|
blob
|
history
diff --git
a/src/jalview/util/Comparison.java
b/src/jalview/util/Comparison.java
index
9fea705
..
e9ff931
100644
(file)
--- a/
src/jalview/util/Comparison.java
+++ b/
src/jalview/util/Comparison.java
@@
-337,9
+337,9
@@
public class Comparison
// a long sequence.
// check for at least 55% nucleotide, and nucleotide and ambiguity codes
// (including N) must make up 95%
// a long sequence.
// check for at least 55% nucleotide, and nucleotide and ambiguity codes
// (including N) must make up 95%
- return ntCount * 100 > NUCLEOTIDE_COUNT_PERCENT * allCount
+ return ntCount * 100 >= NUCLEOTIDE_COUNT_PERCENT * allCount
&& 100 * (ntCount + nCount
&& 100 * (ntCount + nCount
- + ntaCount) > NUCLEOTIDE_COUNT_LONG_SEQUENCE_AMBIGUITY_PERCENT
+ + ntaCount) >= NUCLEOTIDE_COUNT_LONG_SEQUENCE_AMBIGUITY_PERCENT
* allCount;
}
else if (allCount > NUCLEOTIDE_COUNT_VERY_SHORT_SEQUENCE)
* allCount;
}
else if (allCount > NUCLEOTIDE_COUNT_VERY_SHORT_SEQUENCE)
@@
-347,7
+347,7
@@
public class Comparison
// a short sequence.
// check if a short sequence is at least 55% nucleotide and the rest of
// the symbols are all X or all N
// a short sequence.
// check if a short sequence is at least 55% nucleotide and the rest of
// the symbols are all X or all N
- if (ntCount * 100 > NUCLEOTIDE_COUNT_PERCENT * allCount
+ if (ntCount * 100 >= NUCLEOTIDE_COUNT_PERCENT * allCount
&& (nCount == aaCount || xCount == aaCount))
{
return true;
&& (nCount == aaCount || xCount == aaCount))
{
return true;