Browse code

update description

guangchuang yu authored on 08/03/2017 10:37:31
Showing 3 changed files

... ...
@@ -21,6 +21,7 @@ Imports:
21 21
     grid,
22 22
     magrittr,
23 23
     methods,
24
+    rvcheck,
24 25
     tidyr,
25 26
     utils
26 27
 Suggests:
... ...
@@ -181,6 +181,7 @@ importFrom(magrittr,add)
181 181
 importFrom(magrittr,equals)
182 182
 importFrom(methods,is)
183 183
 importFrom(methods,missingArg)
184
+importFrom(rvcheck,get_fun_from_pkg)
184 185
 importFrom(tidyr,gather)
185 186
 importFrom(treeio,as.phylo)
186 187
 importFrom(treeio,as.treedata)
... ...
@@ -459,14 +459,7 @@ getCols <- function (n) {
459 459
     colorRampPalette(col3)(n)
460 460
 }
461 461
 
462
-
463
-get_fun_from_pkg <- function(pkg, fun) {
464
-    ## requireNamespace(pkg)
465
-    ## eval(parse(text=paste0(pkg, "::", fun)))
466
-    require(pkg, character.only = TRUE)
467
-    eval(parse(text = fun))
468
-}
469
-
462
+##' @importFrom rvcheck get_fun_from_pkg
470 463
 hist <- get_fun_from_pkg("graphics", "hist")
471 464
 
472 465