]> git.donarmstrong.com Git - ape.git/blobdiff - R/plotPhyloCoor.R
a fix in cophyloplot()
[ape.git] / R / plotPhyloCoor.R
index 8ede4df55bf89aaa871b4b6eca72011658347761..35f9ae4e8a0a17d011b1de1120bdbc49689c3b07 100644 (file)
@@ -1,4 +1,4 @@
-## plotPhyloCoor.R (2008-04-30)
+## plotPhyloCoor.R (2012-02-14)
 
 ##   Coordinates of a Tree Plot
 
@@ -32,7 +32,8 @@ plotPhyloCoor <-
     }
 
     xe <- x$edge
-    x <- reorder(x, order = "pruningwise")
+    ## first reorder the tree in cladewise order to avoid cophyloplot() hanging:
+    x <- reorder(reorder(x), order = "pruningwise")
     ereorder <- match(x$edge[, 2], xe[, 2])
 
     if (phyloORclado) {