From b798682af83d8fb1d7c7f4b45388572899b31cac Mon Sep 17 00:00:00 2001 From: MorellThomas Date: Fri, 15 Mar 2024 10:25:36 +0100 Subject: [PATCH] Fix output of all dimensions --- src/jalview/analysis/PaSiMap.java | 2 +- src/jalview/viewmodel/PaSiMapModel.java | 18 ++++++++++++++---- 2 files changed, 15 insertions(+), 5 deletions(-) diff --git a/src/jalview/analysis/PaSiMap.java b/src/jalview/analysis/PaSiMap.java index 07256a3..96f1e15 100755 --- a/src/jalview/analysis/PaSiMap.java +++ b/src/jalview/analysis/PaSiMap.java @@ -135,7 +135,7 @@ public class PaSiMap implements Runnable for (int i = 0; i < out.length; i++) { - out[i] = component(i, n); + out[i] = component(n, i); } return out; diff --git a/src/jalview/viewmodel/PaSiMapModel.java b/src/jalview/viewmodel/PaSiMapModel.java index ba9ad6a..c2116f8 100644 --- a/src/jalview/viewmodel/PaSiMapModel.java +++ b/src/jalview/viewmodel/PaSiMapModel.java @@ -207,10 +207,20 @@ public class PaSiMapModel for (int s = 0; s < seqs.length; s++) { csv.append("\"" + seqs[s].getName() + "\""); - Point p = points.get(s).coord; - csv.append(",").append(p.x); - csv.append(",").append(p.y); - csv.append(",").append(p.z); + if (!transformed) + { + double[] fl = pasimap.component(s); + for (int d = fl.length - 1; d >= 0; d--) + { + csv.append(","); + csv.append(fl[d]); + } + } else { + Point p = points.get(s).coord; + csv.append(",").append(p.x); + csv.append(",").append(p.y); + csv.append(",").append(p.z); + } csv.append("\n"); } return csv.toString(); -- 1.7.10.2