package_sf: Raster coercion to ”stars”

as_starsR Documentation

Raster coercion to `stars`

Description

Coercion from raster ursaRaster object to raster stars object defined in package stars.

Usage

as_stars(obj)

Arguments

obj

Object of class ursaRaster.

Details

Simple coercion to stars object of package stars. Currently, color tables and attribution tables are not supported.

Value

Object of class stars for argument of class ursaRaster. Otherwise, NULL.

Author(s)

Nikita Platonov platonov@sevin.ru

Examples

session_grid(NULL)
a <- ursa_dummy(3)
x <- as_stars(a)
class(x)
if (requireNamespace("stars")) {
   print(x)
   b <- as_ursa(x)
   print(a)
   print(b)
}

nplatonov/ursa documentation built on Feb. 2, 2024, 4:08 a.m.