Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

installPackages

Install R packages by name or URL


Description

Install R packages by name or URL.

Usage

## Default S3 method:
installPackages(pkgs, types="auto", repos=getOption("repos"), ..., destPath=".",
  cleanup=TRUE)

Arguments

pkgs

A character vector specifying the names and/or the URLs of the R packages to be installed.

types

A character vector of corresponding package types.

repos

A character vector of package repository URLs.

...

Additional arguments passed to install.packages.

destPath

Path where any downloaded files are saved.

cleanup

If TRUE, downloaded and successfully installed package files are removed, otherwise not.

Value

Returns nothing.

Limitations

This method cannot install any packages that are already in use. Certain packages are always in use when calling this method, e.g. R.methodsS3, R.oo, and R.utils.

Author(s)

Henrik Bengtsson

Examples

## Not run: 
 installPackages("R.rsp")
 installPackages("https://cran.r-project.org/src/contrib/Archive/R.rsp/R.rsp_0.8.2.tar.gz")
 installPackages("https://cran.r-project.org/bin/windows/contrib/4.0/R.rsp_0.44.0.zip")

## End(Not run)

R.utils

Various Programming Utilities

v2.10.1
LGPL (>= 2.1)
Authors
Henrik Bengtsson [aut, cre, cph]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.