Description Usage Arguments Details Value See Also Examples
loads
does what the name suggests: it loads
data from a special binary file format (RDatas) made up by
the saves
function. This special,
uncompressed tar archive inlcudes several separate RData
files (saved by save
function) as being
columns/variables of a data.frame.
1 2 |
file |
character string: the (RDatas) filename from
which to load the variables. If using |
variables |
A character vector containing the variable names to load |
to.data.frame |
boolean: the default behavior of
|
ultra.fast |
boolean: if TRUE, ultra fast (...) processing is done without any check to parameters or file existence/permissions. Be sure if using this setting as no debugging is done! Only recommended for servers dealing with lot of R objects' saves and loads in a monitored environment. Also, for performance gain, it is advised not to convert the list to data frame (to.data.frame = FALSE). |
The purpose of this function is to be able only a few variables of a data.frame really fast. It is done by reading and writing datas in binary format without any transformations, and combining the speed of only reading the needed part of an archive.
Some minor experiments shows a huge performance gain against using SQLite/MySQL backends or loading whole binary data, but be conscious always choosing the aprropriate method to write and read data.
The author of this package would like to emphasize: this package could be useful only in few cases!
Loaded data.frame
saves
to save R objects to RDatas binary
format
1 2 3 4 5 6 7 8 | ## Not run:
# Loading the 'v1' and 'v5' variables of the demo dataset.
data(evs.2000.hun)
saves(evs.2000.hun)
evs.filtered.list <- loads("evs.2000.hun.RDatas", c('v1', 'v5'))
evs.filtered.df <- loads("evs.2000.hun.RDatas", c('v1', 'v5'), to.data.frame=TRUE)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.