Alter the format used to save DataFrames in its stageObject methods.

saveDataFrameFormat(format)

Arguments

format

String containing the format to use. Tbe "csv", "csv.gz" (default) or "hdf5". Alternatively NULL, to use the default format.

Value

If format is missing, a string containing the current format is returned, or NULL to use the default format.

If format is supplied, it is used to define the current format, and the previous format is returned.

Details

stageObject methods will treat a format=NULL in the same manner as the default format. The distinction exists to allow downstream applications to set their own defaults while still responding to user specification. For example, an application can detect if the existing format is NULL, and if so, apply another default via .saveDataFrameFormat. On the other hand, if the format is not NULL, this is presumably specified by the user explicitly and should be respected by the application.

Author

Aaron Lun

Examples

(old <- .saveDataFrameFormat())
#> NULL

.saveDataFrameFormat("hdf5")
.saveDataFrameFormat()
#> [1] "hdf5"

# Setting it back.
.saveDataFrameFormat(old)