Make a copy of an environment with just the selected objects.
Make a copy of an environment with just the selected objects.
trim_env(object, keep = NULL, ...) ## S3 method for class 'environment' trim_env(object, keep = NULL, ...) ## Default S3 method: trim_env(object, keep = NULL, ...)
object |
An |
keep |
A character vector giving names of variables in the environment (including its ancestors) to copy over, defaulting to dropping all. Variables that cannot be resolved are silently ignored. |
... |
Additional arguments, passed on to lower-level methods. |
An object of the same type as object, with updated environment.
environment: A method for environment objects.
default: Default method, for objects such as formula and function that have environment() and environment()<- methods.
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.