get_deps | R Documentation |
Get Package Dependencies
get_deps(path)
path |
character vector of length one having the directory path to where new version of the custom package exists. This can be the full path name of the directory in which the package exists or the full path name of the source version of the package. |
Character vector of package dependencies based on the contents of
the DESCRIPTION
file.
Written by Josh O'Brien on stackoverflow on May 13 '15 at 21:42
## Not run:
library(rmsutilityr)
## Directory where package is placed when installed.
dependencies <- get_deps("c:/R library/snprcspf")
## Source file of package
dependencies <- get_deps("c:/R data/snprcspf.1.0.1.tar.gz")
remove_these <- c("stats", "tools", "utils", "rmsutilityr", "animalr")
dependencies <- remove_these_str(dependencies, expunge = remove_these)
repo <- "https://cran.revolutionanalytics.com" ## or your mirror of choice
lib_path <- "c:/R Library/"
install.packages(dependencies, type = "binary", repos = repo, lib = lib_path)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.