JAL-2805 Creating jalview sequence now requires the node itself (for the
authorkjvdheide <kjvanderheide@dundee.ac.uk>
Tue, 9 Jan 2018 17:34:11 +0000 (17:34 +0000)
committerkjvdheide <kjvanderheide@dundee.ac.uk>
Tue, 9 Jan 2018 17:34:11 +0000 (17:34 +0000)
name)

src/jalview/ext/archaeopteryx/TreeNode.java
src/jalview/ext/forester/DataConversions.java

index 69077dc..b43e9b4 100644 (file)
@@ -32,7 +32,7 @@ public class TreeNode implements TreeNodeI
     if (aptxNode.getNodeData().getSequence() != null)
     {
     nodeSeq = DataConversions
-              .createJalviewSequence(aptxNode.getNodeData().getSequence());
+              .createJalviewSequence(aptxNode);
     }
     originalNodes.put(aptxNode, this);
     wrappedNodes.put(this, aptxNode);
index 4985f5f..c6819a5 100644 (file)
@@ -6,6 +6,7 @@ import jalview.math.MatrixI;
 
 import org.forester.evoinference.matrix.distance.DistanceMatrix;
 import org.forester.io.parsers.phyloxml.PhyloXmlDataFormatException;
+import org.forester.phylogeny.PhylogenyNode;
 
 public final class DataConversions
 {
@@ -42,10 +43,13 @@ public final class DataConversions
   }
 
   public static SequenceI createJalviewSequence(
-          org.forester.phylogeny.data.Sequence foresterSeq)
+          PhylogenyNode foresterNode)
   {
-    String seq = foresterSeq.getMolecularSequence();
-    SequenceI jalviewSeq = new Sequence(foresterSeq.getName(), seq, 1,
+    String seq = foresterNode.getNodeData().getSequence()
+            .getMolecularSequence();
+    String seqName = foresterNode.getName();
+
+    SequenceI jalviewSeq = new Sequence(foresterNode.getName(), seq, 1,
             seq.length() + 1);
     return jalviewSeq.deriveSequence();