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
/
AverageDistanceEngine.java
diff --git
a/src/jalview/analysis/AverageDistanceEngine.java
b/src/jalview/analysis/AverageDistanceEngine.java
index
e6a763b
..
f4d69d5
100644
(file)
--- a/
src/jalview/analysis/AverageDistanceEngine.java
+++ b/
src/jalview/analysis/AverageDistanceEngine.java
@@
-100,11
+100,18
@@
public class AverageDistanceEngine extends TreeEngine
// compute distance matrix element
ContactListI ith = cm.getContactList(i);
// compute distance matrix element
ContactListI ith = cm.getContactList(i);
-
+ distances.setValue(i, i, 0);
+ if (ith==null)
+ {
+ continue;
+ }
for (int j = 0; j < i; j++)
{
for (int j = 0; j < i; j++)
{
- distances.setValue(i, i, 0);
ContactListI jth = cm.getContactList(j);
ContactListI jth = cm.getContactList(j);
+ if (jth == null)
+ {
+ break;
+ }
double prd = 0;
for (int indx = 0; indx < cm.getHeight(); indx++)
{
double prd = 0;
for (int indx = 0; indx < cm.getHeight(); indx++)
{