X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=src%2Fjalview%2Fanalysis%2FTreeBuilder.java;fp=src%2Fjalview%2Fanalysis%2FTreeBuilder.java;h=5381880e05d8b31c1894a1cbb1fe23084457a1b0;hb=21d7606604dab27e62ed700a39425b983901cef1;hp=5347ba23cb8a9723b8f2d31ab49d05561c92bc85;hpb=933794f42ed55d57850424e3459a54cd2d92c933;p=jalview.git diff --git a/src/jalview/analysis/TreeBuilder.java b/src/jalview/analysis/TreeBuilder.java index 5347ba2..5381880 100644 --- a/src/jalview/analysis/TreeBuilder.java +++ b/src/jalview/analysis/TreeBuilder.java @@ -253,6 +253,12 @@ public abstract class TreeBuilder findMaxDist(top); } + /** + * Returns the minimum distance between two clusters, and also sets the + * indices of the clusters in fields mini and minj + * + * @return + */ protected abstract double findMinDistance(); /** @@ -295,10 +301,10 @@ public abstract class TreeBuilder } /** - * DOCUMENT ME! + * Finds the node, at or below the given node, with the maximum distance, and + * saves the node and the distance value * * @param nd - * DOCUMENT ME! */ void findMaxDist(SequenceNode nd) { @@ -325,14 +331,12 @@ public abstract class TreeBuilder } /** - * DOCUMENT ME! + * Calculates and returns r, whatever that is * * @param i - * DOCUMENT ME! * @param j - * DOCUMENT ME! * - * @return DOCUMENT ME! + * @return */ protected double findr(int i, int j) { @@ -428,8 +432,12 @@ public abstract class TreeBuilder done.set(j); } - protected abstract void findNewDistances(SequenceNode tmpi, SequenceNode tmpj, - double dist); + /* + * Computes and stores new distances for nodei and nodej, given the previous + * distance between them + */ + protected abstract void findNewDistances(SequenceNode nodei, + SequenceNode nodej, double previousDistance); /** * Calculates and saves the distance between the combination of cluster(i) and