Write a `parcel_data` Object to Disk
Usage
write_parcel_data(x, file, format = c("auto", "rds", "json"), pretty = TRUE)Examples
x <- parcel_data(data.frame(
id = 1:2, label = c("A", "B"),
hemi = c("left", "right"), value = c(0.2, 0.7)
), atlas_id = "toy")
file <- tempfile(fileext = ".rds")
write_parcel_data(x, file)
read_parcel_data(file)
#> parcel_data
#> schema: 1.0.0
#> atlas: toy
#> parcels: 2
#> value_cols: value
unlink(file)