wrapCache | R Documentation |
Use wrap
to pack a SpatRaster with caching options. See wrap
for the general approach that is easier and better to use in most cases.
This method allows for specifying a folder, or filenames, to cache all sources of a SpatRaster in a specific location (on disk).
## S4 method for signature 'SpatRaster'
wrapCache(x, filename=NULL, path=NULL, overwrite=FALSE, ...)
x |
SpatRaster |
filename |
character. A single filename, or one filename per SpatRaster data source. If not |
path |
character. If not |
overwrite |
Should existing files be overwritten when |
... |
Additional arguments for |
PackedSpatRaster
wrap
, unwrap
f <- system.file("ex/elev.tif", package="terra")
r <- rast(f)
x <- wrapCache(r, path=tempdir())
x
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.