Description Usage Arguments Details References See Also Examples
remove
and rm
can be used to remove objects. These can
be specified successively as character strings, or in the character
vector list
, or through a combination of both. All objects
thus specified will be removed.
If envir
is NULL then the currently active environment is
searched first.
If inherits
is TRUE
then parents of the supplied
directory are searched until a variable with the given name is
encountered. A warning is printed for each variable that is not
found.
1 2 3 4 5 |
... |
the objects to be removed, as names (unquoted) or character strings (quoted). |
list |
a character vector naming objects to be removed. |
pos |
where to do the removal. By default, uses the current environment. See ‘details’ for other possibilities. |
envir |
the |
inherits |
should the enclosing frames of the environment be inspected? |
The pos
argument can specify the environment from which to remove
the objects in any of several ways:
as an integer (the position in the search
list); as
the character string name of an element in the search list; or as an
environment
(including using sys.frame
to
access the currently active function calls).
The envir
argument is an alternative way to specify an
environment, but is primarily there for back compatibility.
It is not allowed to remove variables from the base environment and
base namespace, nor from any environment which is locked (see
lockEnvironment
).
Earlier versions of R incorrectly claimed that supplying a character
vector in ...
removed the objects named in the character
vector, but it removed the character vector. Use the list
argument to specify objects via a character vector.
Becker, R. A., Chambers, J. M. and Wilks, A. R. (1988) The New S Language. Wadsworth & Brooks/Cole.
1 2 3 4 5 6 7 8 9 10 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.