keep: The Keep Function

View source: R/keep.R

keepR Documentation

The Keep Function

Description

This function is designed to keep a given list of variables (as opposed to the rm function, which is designed to remove a list of variables)

Usage

keep(..., x = c())

Arguments

...

Variables that should stay in the environment

x

A character vector of variables which you wish to keep

Details

The function uses the ls command to find the variables that are defined in the parent environment. It then deletes all variables that are not given as an argument.

Author(s)

Michael Floren

See Also

rm


bbcuffer/rcutils documentation built on Nov. 10, 2023, 12:08 p.m.