Fungsi ini mengambil vektor nama objek R dan menghasilkan representasi teks dari objek pada file atau koneksi. File dump biasanya dapat bersumber ke sesi R lain.
dump(list, file = "dumpdata.R", append = FALSE,
control = "all", envir = parent.frame(), evaluate = TRUE)
| Parameter | Deskripsi |
|---|---|
list |
character vector. The names of one or more R objects to be dumped. |
file |
either a character string naming a file or a connection. "" indicates output to the console. |
append |
if TRUE and file is a character string, output will be appended to file; otherwise, it will overwrite the contents of file. |
control |
character vector indicating deparsing options. See .deparseOpts for their description. |
envir |
the environment to search for objects. |
evaluate |
logical. Should promises be evaluated? |
# NOT RUN {
x <- 1; y <- 1:10
fil <- tempfile(fileext=".Rdmped")
dump(ls(pattern = '^[xyz]'), fil)
print(.Last.value)
unlink(fil)
# }