Created
May 13, 2026 18:34
-
-
Save jangorecki/87d91fed78aef9f8022b6a914fe7f26a to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| mem <- function(.gc_start) { | |
| .gc_end <- gc(verbose = FALSE, reset = FALSE) | |
| round(sum((.gc_end[, 5L] - .gc_start[, 5L]) * c(56, 8)) / 1024^2, 3) | |
| } | |
| .gc <- gc(verbose = FALSE, reset = TRUE) | |
| for (i in 1:3) rnorm(1e8) | |
| print(mem(.gc)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment