Skip to contents

Wraps an hr_tt_ud_tbl before saving it with base::saveRDS(). This avoids writing live terra::SpatRaster objects to disk. The object returned by base::readRDS() has a wrapped ud column. Functions that operate on an hr_tt_ud_tbl unwrap this column automatically; use hr_tt_ud_unwrap() to restore it explicitly for repeated analyses.

Usage

hr_tt_ud_saveRDS(x, file, compress = TRUE, version = NULL, ...)

hr_ud_saveRDS(...)

Arguments

x

An hr_tt_ud_tbl with a ud list-column.

file

A connection or character string naming the RDS file.

compress

A logical or character value passed to base::saveRDS().

version

The RDS serialization format version passed to base::saveRDS().

...

Additional arguments passed to base::saveRDS().

Value

NULL, invisibly.

Examples

if (FALSE) { # \dontrun{
example_kde <- hr_tt_kde(example_tt)
hr_tt_ud_saveRDS(example_kde, "example-kde.rds")
loaded_kde <- readRDS("example-kde.rds")
} # }