Browse code

better msg

Guangchuang Yu authored on 07/11/2018 10:56:47
Showing 3 changed files

... ...
@@ -2,7 +2,7 @@ Package: ggtree
2 2
 Type: Package
3 3
 Title: an R package for visualization and annotation of phylogenetic trees with
4 4
     their covariates and other associated data
5
-Version: 1.15.0
5
+Version: 1.15.1
6 6
 Authors@R: c(
7 7
 	   person("Guangchuang", "Yu",     email = "guangchuangyu@gmail.com", role = c("aut", "cre", "cph"), comment = c(ORCID = "0000-0002-6485-8781")),
8 8
 	   person("Tommy Tsan-Yuk", "Lam", email = "tylam.tommy@gmail.com",   role = c("aut", "ths")),
... ...
@@ -1,3 +1,12 @@
1
+# ggtree 1.15.1
2
+
3
++ better msg when taxa name not consistent in sequence and tree files with `msaplot`. (2018-11-07, Wed)
4
+  - <https://github.com/GuangchuangYu/ggtree/issues/172#issuecomment-436585370>
5
+  
6
+# ggtree 1.14.0
7
+
8
++ Bioconductor 3.8 release
9
+
1 10
 # ggtree 1.13.6
2 11
 
3 12
 + set `scale_y_continuous(expand = c(0, 0))` for `gheatmap` when `colnames = FALSE` (2018-10-17, Wed)
... ...
@@ -41,6 +41,10 @@ msaplot <- function(p, fasta, offset=0, width=1, color=NULL, window=NULL, bg_lin
41 41
 
42 42
     x <- as.matrix(x)
43 43
 
44
+    if (!all(labels(x) %in% p$data$label)) {
45
+        stop("taxa name in input sequences are not match with the ones on the tree, please check your input files...")
46
+    }
47
+
44 48
     if (is.null(window)) {
45 49
         window <- c(1, ncol(x))
46 50
     }