cacheit | R Documentation |
Save results from code that takes a long time to execute to a .rds file if that file does not exist in the cache directory. If the file exists in the cache directory, that file will be loaded to memory without evaluating the code.
cacheit(name, code, dir, createdir = FALSE, clearcache = FALSE)
name |
Name of the file to create without extension |
code |
Expression of the code to execute and cache |
dir |
Name of cache directory which should be placed in the working directory |
createdir |
Logical about whether to create the directory if it does not exist |
clearcache |
Logical about whether to recalculate the cached .rds file for this object |
For more information, please refer to the vignette using
browseVignettes("nncc")
.
Output of code, either freshly executed if the file does not exist or or clearcache is TRUE otherwise returns result from the cache file
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.