Learn R Programming

switchr (version 0.14.8)

head: Head and tail operations on manifests

Description

Head and tail operations on manifests

Usage

head(x, ...)

# S4 method for SessionManifest head(x, n = 5, ...)

# S4 method for PkgManifest head(x, n = 5, ...)

tail(x, ...)

# S4 method for SessionManifest tail(x, n = 5, ...)

# S4 method for PkgManifest tail(x, n = 5, ...)

Value

An object of the same type as x containing n packages

Arguments

x

A manifest object

...

unused

n

The number of packages to keep

Details

In the case of a PkgManifest, the first or last n packages are retained in the manifest, while all others are removed.

In the case of a SessionManifest, n specified versions are retained, while the underlying PkgManifest is unchanged.