rtry_export: Export preprocessed data

View source: R/export.R

rtry_exportR Documentation

Export preprocessed data

Description

This function exports the preprocessed data as comma separated values to a .csv file. If the specified output directory does not exist, it will be created.

Usage

rtry_export(data, output, quote = TRUE, encoding = "UTF-8")

Arguments

data

The data to be saved.

output

Output path.

quote

Default TRUE inserts double quotes around any character or factor columns.

encoding

Default "UTF-8". File encoding.

Value

No return value, called for exporting a .csv file.

References

This function makes use of the write.csv function within the utils package.

Examples

# Export the preprocessed data to a specific location
rtry_export(data_TRY_15160, file.path(tempdir(), "TRYdata_unprocessed.csv"))

# Expected message:
# File saved at: C:\Users\user\AppData\Local\Temp\Rtmp4wJAvQ/TRYdata_unprocessed.csv

rtry documentation built on Aug. 10, 2023, 1:07 a.m.