Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

env.copy

Deep copy and printing of an environment


Description

Deep copy and printing of an environment.

Usage

env.copy(x,all.names=FALSE)
## S3 method for class 'environment'
print(x,all.names=FALSE,...)

Arguments

x

An environment object.

all.names

An logical value (TRUE or FALSE):

env.copy: copy all the hidden variables or not print.environment: print all the hidden variables or not

...

Anything the user want.

Details

env.copy: deep copy of the environment object. print.environment: print the name, type and length or dimension of each variable inside environment. For printing the hidden objects set second argument to TRUE, by default it is FALSE.

Value

env.copy: A copy of the first argument.

Author(s)

R implementation and documentation: Manos Papadakis <papadakm95@gmail.com>.

See Also

Examples

x <- new.env()
x$imaginary <- NULL
x$real <- NULL

# you can library the package and just press x and R will understand 
# and search automatically for a function to print the environment
x

y <- env.copy(x)

x$real <- 10

x$real == y$real # FALSE

Rfast

A Collection of Efficient and Extremely Fast R Functions

v2.0.1
GPL (>= 2.0)
Authors
Manos Papadakis, Michail Tsagris, Marios Dimitriadis, Stefanos Fafalios, Ioannis Tsamardinos, Matteo Fasiolo, Giorgos Borboudakis, John Burkardt, Changliang Zou, Kleanthi Lakiotaki and Christina Chatzipantsiou.
Initial release
2020-09-13

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.