Reload Rmarkdown cache in the order files were created
character
path to the directory that contains Rmarkdown
cache files. Each file is recognized by the file extension ".rdx"
.
integer
indicating the maximum number of cache files
to re-load, in order.
character
optional string indicating the
name of an Rmarkdown cache chunk where this function will stop
loading cache data. All cache files after this point will
not be loaded. This option is intended to help recreate the
data available to a particular Rmarkdown chunk during
processing.
environment
where cache data will be loaded.
character
string indicating how to sort cache files
to place them in proper order for re-loading. The default is to use
one RMarkdown cache index file, which should accurately reflect only
RMarkdown chunks present in the .Rmd file during rendering, and
in the order they appear in that file.
Using "mtime"
or "ctime"
below will sort files by the modification
or creation time, respectively, and is less accurate, but often
sufficient for most purposes. It would only be advised if for
some reason the "__globals"
or "__objects"
files are not present.
"globals"
uses the "__globals"
file in the cache directory.
"objects"
uses the "__objects"
file in the cache directory.
ctime
sorts by file creation time, default
mtime
sorts by file modification time
character
string indicating the preferred
load mechanism to use. By default it will use lazyLoad()
if .rdx/.rdb
files are present, otherwise it falls back to using load()
for .RData
files.
Remove "lazyLoad"
to prevent lazy-loading of cached objects.
"lazyLoad"
will try to use lazyLoad()
to load .rdx/.rdb
files
"load"
will try to use load()
to load .RData
files
logical
indicating whether to perform a dry-run,
which prints messages but does not process the data.
logical
indicating whether to print verbose output.
Note that this variable is not passed along to load()
, since it
is inconsistent with lazyLoad()
.
additional arguments are passed to lazyLoad()
or load()
as relevant to the method used to re-load the cache object data.
this function does not return data, but instead is called
for the by-product of loading data into the given envir
environment.
This function is intended to help re-load Rmarkdown cache files created during the processing/rendering of an Rmarkdown file.
By default, all cached R objects are loaded into the
global environment globalenv()
.
It can be given an argumen envir
to store R objects inside
a specific environment
.
If supplied with max_cache_name
then this function will only
load the cache chunks in order, until it recognizes that
chunk name. This option is intended to help restore the R
data available for a particular Rmarkdown chunk.
Other jam utility functions:
call_fn_ellipsis()