repo_stash {repo} | R Documentation |
Quickly store temporary data
Description
A very simplified call to put that only requires to specify a variable name.
Usage
repo_stash(object, rename = deparse(substitute(object)))
Arguments
object |
The object to store in the repo. |
rename |
An optional character containing the new name for the item. Otherwise the name of object is used as item's name. |
Details
The name
parameter is used to search the parent (or a
different specified) environment for the actual object to
store. Then it is also used as the item name. The reserved tags
"stash" and "hide" are set. In case a stashed item by the same
name already exists, it is automatically overwritten. In case a
non-stashed item by the same name already exists, an error is
raised. A different name can be specified through the rename
parameter in such cases.
Value
Used for side effects.
See Also
repo_put, repo_lazydo
Examples
## Not run:
rp_path <- file.path(tempdir(), "example_repo")
rp <- repo_open(rp_path, TRUE)
tempdata <- runif(10)
rp$stash(tempdata)
rp$info("tempdata")
## wiping temporary repo
unlink(rp_path, TRUE)
## End(Not run)
[Package repo version 2.1.5 Index]