From: Ben Soares Date: Thu, 23 Feb 2023 16:18:40 +0000 (+0000) Subject: JAL-629 fix a PAEMatrix casting error X-Git-Tag: Release_2_11_4_0~483 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=8479d86d490c841168c9eed1ac80960ce4191c78;p=jalview.git JAL-629 fix a PAEMatrix casting error --- diff --git a/src/jalview/ws/datamodel/alphafold/PAEContactMatrix.java b/src/jalview/ws/datamodel/alphafold/PAEContactMatrix.java index 272d21d..f282b9f 100644 --- a/src/jalview/ws/datamodel/alphafold/PAEContactMatrix.java +++ b/src/jalview/ws/datamodel/alphafold/PAEContactMatrix.java @@ -71,7 +71,11 @@ public class PAEContactMatrix implements ContactMatrixI Iterator scores = scoreRows.next().iterator(); while (scores.hasNext()) { - elements[row][col++] = scores.next(); + Object d = scores.next(); + if (d instanceof Double) + elements[row][col++] = ((Double) d).longValue(); + else + elements[row][col++] = (float) d; } row++; col = 0;