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

mem_change

Determine change in memory from running code


Description

Determine change in memory from running code

Usage

mem_change(code)

Arguments

code

Code to evaluate.

Value

Change in memory (in megabytes) before and after running code.

Examples

# Need about 4 mb to store 1 million integers
mem_change(x <- 1:1e6)
# We get that memory back when we delete it
mem_change(rm(x))

pryr

Tools for Computing on the Language

v0.1.4
GPL-2
Authors
Hadley Wickham [aut, cre], R Core team [ctb] (Some code extracted from base R)
Initial release

We don't support your browser anymore

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