unbind: Save each column of a data frame to a separate file

Description Usage Arguments Details References

View source: R/unbind.R

Description

This function save the data for each column of a data frame to a separate RDS file. If the target directory does not exist, it is created, including intermediate directories. Compression is optional.

Usage

1
unbind(x, .destdir, .compress = TRUE, .parallel = FALSE)

Arguments

x

A data frame

.destdir

Where to save the files. For proper operation, it cannot contain other files with .rds extension.

.compress

Passed as compress to save

.parallel

If true, parallelize with mclapply

Details

Use this function in a helper script for your package to add the files needed for column-wise loading this data set, e.g., in the data-raw directory. According to the "Writing R Extensions" manual, "the convention has grown up to use directory inst/extdata for [other data files needed by the package]"; use a subdirectory for each data frame.

References

R packages: External data

Writing R extensions


krlmlr/dfunbind documentation built on May 20, 2019, 6:16 p.m.