cache_object | R Documentation |
Cache object
cache_object(expr, filename, renew = F, ...)
expr |
An expression |
filename |
A filename to use |
renew |
Whether to force renewal of the object |
... |
Other arguments passed to |
An object
i = cache_object(MASS::mvrnorm(1e6, rep(0, 3), matrix(c(1, .4, .4, .4, 1, .4, .4, .4, 1), ncol = 3)), "test_object.rds")
i = cache_object(stop("This is not evaluated"), "test_object.rds")
i = cache_object(warning("But this is"), "test_object.rds", renew = T)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.