Description Usage Arguments Format Examples
A DiskInterface objects holds methods for reading and writing objects from disk in
a particular format. We assume that your "disk" is your local disk, as we use
base R functions such as file.exists
to interact with objects.
1 |
read_fn |
function. Used to read objects from disk to R. |
write_fn |
function. Used to write objects from R to disk. |
An object of class R6ClassGenerator
of length 24.
1 2 3 4 5 6 7 8 | ## Not run:
RDS <- DiskInterface$new(read_fn, write_fn)
# read an RDS file into R
df <- RDS$read("~/files/df.RDS")
# write an object to an RDS file
RDS$write(df2, "~/files/df2.RDS")
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.