Description Usage Arguments Details Author(s) Examples
View source: R/loadinstall_libraries.R
Call this function to load a vector of required packages from CRAN. It will try to load the packages, and intall them if they are missing.
1 2 3 4 5 | loadinstall_libraries(
required_packages = c(),
myrepos = options()$repos,
install_only = FALSE
)
|
required_packages |
Character vector of pacakges to load / install The default is "", in which case it doesn't try to install anything. |
myrepos |
Repository to use. Default is "http://cran.rstudio.com/" |
install_only |
Boolean to indicate if the packages are only to be installed, instead of installed an loaded. |
You may wish to update the default repo: "http://cran.rstudio.com/" ## ## 2014-03-31 SJR Extracted this function from 00_Initialize.R ## 2014-05-05 GWL Adding function to geneorama package ##
Gene Leynes
1 2 3 4 5 6 7 8 9 | ## Warning: this will install these packages if you don't already have
## them
## Not run:
require(geneorama)
loadinstall_libraries(c("ggplot2", "data.table"))
## End(Not run)
require(geneorama)
lll()
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.