installed.versions: installed.versions

Description Usage Arguments Value Examples

Description

List the installed versions of packages in a library directory

Usage

1
installed.versions(pkgs, lib)

Arguments

pkgs

character vector of the names of packages for which to query the installed versions

lib

character vector of length one giving the library directory containing the packages to query. If missing, defaults to the first element of .libPaths().

Value

a named character vector of version numbers corresponding to pkgs, with names giving the package names. If a packakge could not be found in lib, an NA will be returned.

Examples

1
2
3
4
5
6
7
8
9
# the versions of versions
installed.versions('versions')

# apply to multiple packages
installed.versions(c('stats', 'versions'))

# add a package that doesn't exist or isn't installed
# (returns NA for that one)
installed.versions(c('stats', 'versions', 'notapackage'))

versions documentation built on May 2, 2019, 7:58 a.m.