git://source.jalview.org
/
jalview.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
JAL-4235 JAL-3599 Try and report Eclipse Product Version for jalviewjsTranspile....
[jalview.git]
/
src
/
jalview
/
analysis
/
NJTree.java
diff --git
a/src/jalview/analysis/NJTree.java
b/src/jalview/analysis/NJTree.java
index
487e85e
..
9a39ac0
100644
(file)
--- a/
src/jalview/analysis/NJTree.java
+++ b/
src/jalview/analysis/NJTree.java
@@
-22,7
+22,7
@@
package jalview.analysis;
import jalview.api.analysis.ScoreModelI;
import jalview.api.analysis.SimilarityParamsI;
import jalview.api.analysis.ScoreModelI;
import jalview.api.analysis.SimilarityParamsI;
-import jalview.datamodel.SequenceNode;
+import jalview.datamodel.BinaryNode;
import jalview.viewmodel.AlignmentViewport;
/**
import jalview.viewmodel.AlignmentViewport;
/**
@@
-81,7
+81,7
@@
public class NJTree extends TreeBuilder
* {@inheritDoc}
*/
@Override
* {@inheritDoc}
*/
@Override
- protected void findNewDistances(SequenceNode nodei, SequenceNode nodej,
+ protected void findNewDistances(BinaryNode nodei, BinaryNode nodej,
double dist)
{
nodei.dist = ((dist + ri) - rj) / 2;
double dist)
{
nodei.dist = ((dist + ri) - rj) / 2;
@@
-108,25
+108,25
@@
public class NJTree extends TreeBuilder
* @param j
*/
@Override
* @param j
*/
@Override
- protected
- void findClusterDistance(int i, int j)
+ protected void findClusterDistance(int i, int j)
{
// New distances from cluster i to others
double[] newdist = new double[noseqs];
{
// New distances from cluster i to others
double[] newdist = new double[noseqs];
-
+
double ijDistance = distances.getValue(i, j);
for (int l = 0; l < noseqs; l++)
{
if ((l != i) && (l != j))
{
double ijDistance = distances.getValue(i, j);
for (int l = 0; l < noseqs; l++)
{
if ((l != i) && (l != j))
{
- newdist[l] = (distances.getValue(i, l) + distances.getValue(j, l) - ijDistance) / 2;
+ newdist[l] = (distances.getValue(i, l) + distances.getValue(j, l)
+ - ijDistance) / 2;
}
else
{
newdist[l] = 0;
}
}
}
else
{
newdist[l] = 0;
}
}
-
+
for (int ii = 0; ii < noseqs; ii++)
{
distances.setValue(i, ii, newdist[ii]);
for (int ii = 0; ii < noseqs; ii++)
{
distances.setValue(i, ii, newdist[ii]);