stw_read_dataset: Read or write a steward dataset

Description Usage Arguments Details Value

View source: R/stw_read_write_dataset.R

Description

This will read from or write to a set of files: a CSV file for the data, and a YAML file for the meta-data.

Usage

1
2
3
stw_read_dataset(file_data, file_meta = NULL, ...)

stw_write_dataset(dataset, file_data, file_meta = NULL, ...)

Arguments

file_data

character, path to write the CSV file

file_meta

character, path to write the YAML file; default is to use the wame directory and file-root as file_data

...

additional arguments passed on to readr::read_csv() or readr::write_csv()

dataset

Object with S3 class stw_dataset, a data frame with attached meta-data

Details

At the moment, this provides minimal functionality. In the future, we can imagine usung the metadata to create a function that would read a file that comports to the meta-data specifications. The data frame would have all its factor levels set, and in the farther future, have a timezone set for datetime columns.

Value

invisible copy of dataset


uncoast-unconf/steward documentation built on Jan. 7, 2021, 10:38 a.m.