# Store a dataset as rda file
path_project <- tempfile(pattern = "data-")
path_data <- file.path(path_project, "data")
dir.create(path_data, recursive = TRUE)
path_rda <- file.path(path_data, "iris.rda")
save(iris, file = path_rda)
# Get its information
withr::with_dir(
path_project,
{
get_data_info("iris", "Iris data frame", source = "ThinkR")
}
)
# Clean userspace
unlink(path_project, recursive = TRUE)
Run the code above in your browser using DataLab