R: Replace an object's environment with a simple, static...

empty_env {statnet.common} | R Documentation

## Replace an object's environment with a simple, static environment.

### Description

Replace an object's environment with a simple, static environment.

### Usage

    empty_env(object)

    base_env(object)

### Arguments

`object` | An object with the `environment()<-` method.

### Value

An object of the same type as `object`, with updated environment.

### Examples

    f <- y~x
    environment(f) # GlobalEnv

    environment(empty_env(f)) # EmptyEnv

    environment(base_env(f)) # base package environment

[Package statnet.common version 4.6.0 Index]