Skip to content

Commit

Permalink
sand function to install suggested packages (#9).
Browse files Browse the repository at this point in the history
  • Loading branch information
gaborcsardi committed Feb 23, 2014
1 parent 9a4eeb6 commit aed350a
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 5 deletions.
11 changes: 6 additions & 5 deletions R/sand-package.r
@@ -1,5 +1,6 @@
#' sand
#'
#' @name sand
#' @docType package
NULL

install_sand_packages <- function() {
pkgs <- strsplit(packageDescription("sand")$Suggests, "[, \n]+")[[1]]
source("http://bioconductor.org/biocLite.R")
biocLite(pkgs, suppressUpdates=TRUE, suppressAutoUpdate=TRUE)
}
20 changes: 20 additions & 0 deletions man/install_sand_packages.Rd
@@ -0,0 +1,20 @@
\name{install_sand_packages}
\alias{install_sand_packages}
\title{Install all packages used in the book}
\description{This function makes it easy to download and install
all R packages that are used in the book \sQuote{Statistical Analysis
of Network Data with R}.
}
\usage{
install_sand_packages()
}
\details{
The function uses the BioConductor installer, as this can
install both all required BioConductor and CRAN packages.
}
\value{
Returns the names of the installed packages, invisibly.
}
\author{
Gabor Csardi \email{csardi.gabor@gmail.com}
}

0 comments on commit aed350a

Please sign in to comment.