Learn R Programming

SpaDES.core (version 0.2.7)

objSize.simList: Object size for simList

Description

Recursively, runs objSize on the simList environment, so it estimates the correct size of functions stored there (e.g., with their enclosing environments) plus, it adds all other "normal" elements of the simList, e.g., object.size(completed(sim)).

Usage

# S3 method for simList
objSize(
  x,
  quick = getOption("reproducible.quick", FALSE),
  enclosingEnvs = TRUE,
  .prevEnvirs = list(),
  ...
)

Arguments

x

An object

quick

Logical. Only some methods use this. e.g., Path class objects. In which case, file.size will be used instead of object.size.

enclosingEnvs

Logical indicating whether to include enclosing environments. Default TRUE.

.prevEnvirs

For internal account keeping to identify and prevent duplicate counting

...

Additional arguments (currently unused)

Examples

Run this code
# NOT RUN {
a <- simInit(objects = list(d = 1:10, b = 2:20))
objSize(a)
object.size(a)
# }

Run the code above in your browser using DataLab