From 7eb624fa9a8ba8ea20456d1e5f55b773aab0ffba Mon Sep 17 00:00:00 2001 From: Danielle Callan Date: Wed, 10 Jan 2024 12:25:10 -0500 Subject: [PATCH] strokeWidth -> weight for network links --- schema/library.raml | 2 +- schema/url/networks.raml | 2 +- .../plugin/correlation/AbstractCorrelationBipartiteNetwork.java | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/schema/library.raml b/schema/library.raml index 53279a33..206bb3fa 100644 --- a/schema/library.raml +++ b/schema/library.raml @@ -926,7 +926,7 @@ types: properties: source: NodeData target: NodeData - strokeWidth: string + weight: string color: string NetworkData: type: object diff --git a/schema/url/networks.raml b/schema/url/networks.raml index 8fbe5752..96ade114 100644 --- a/schema/url/networks.raml +++ b/schema/url/networks.raml @@ -11,7 +11,7 @@ types: properties: source: NodeData target: NodeData - strokeWidth: string + weight: string color: string NetworkData: diff --git a/src/main/java/org/veupathdb/service/eda/ds/plugin/correlation/AbstractCorrelationBipartiteNetwork.java b/src/main/java/org/veupathdb/service/eda/ds/plugin/correlation/AbstractCorrelationBipartiteNetwork.java index f77316fd..a90d2908 100644 --- a/src/main/java/org/veupathdb/service/eda/ds/plugin/correlation/AbstractCorrelationBipartiteNetwork.java +++ b/src/main/java/org/veupathdb/service/eda/ds/plugin/correlation/AbstractCorrelationBipartiteNetwork.java @@ -95,7 +95,7 @@ protected void writeResults(OutputStream out, Map dataStrea LinkData link = new LinkDataImpl(); link.setSource(sourceNode); link.setTarget(targetNode); - link.setStrokeWidth(String.valueOf(Math.abs(Float.parseFloat(correlationRow.getCorrelationCoef())))); + link.setWeight(String.valueOf(Math.abs(Float.parseFloat(correlationRow.getCorrelationCoef())))); // Link color is the sign of the correlation String color = Float.parseFloat(correlationRow.getCorrelationCoef()) < 0 ? "-1" : "1"; link.setColor(color);