Skip to contents

Write out a Dataset JSON file

Usage

write_dataset_json(x, file, pretty = FALSE)

Arguments

x

datasetjson object

file

File path to save Dataset JSON file

pretty

If TRUE, write with readable formatting

Value

NULL when file written to disk, otherwise character string

Examples

# Write to character object
ds_json <- dataset_json(iris, "IG.IRIS", "IRIS", "Iris", iris_items)
js <- write_dataset_json(ds_json)

# Write to disk
if (FALSE) {
  write_dataset_json(ds_json, "path/to/file.json")
}