R spatial conversions
r_spatial_conversions.Rd
R spatial conversions
Usage
# S4 method for sf
as.sp(x)
# S4 method for SpatVector
as.sp(x)
# S4 method for stars
as.sp(x)
# S4 method for Spatial
as.sp(x)
# S4 method for giottoPolygon
as.sp(x, drop = TRUE)
# S4 method for giottoPoints
as.sp(x, drop = TRUE)
# S4 method for SpatVector
as.sf(x)
# S4 method for Spatial
as.sf(x)
# S4 method for stars
as.sf(x)
# S4 method for sf
as.sf(x)
# S4 method for giottoPolygon
as.sf(x, drop = TRUE)
# S4 method for giottoPoints
as.sf(x, drop = TRUE)
# S4 method for SpatVector
as.stars(x)
# S4 method for sf
as.stars(x)
# S4 method for Spatial
as.stars(x)
# S4 method for stars
as.stars(x)
# S4 method for giottoPolygon
as.stars(x, drop = TRUE)
# S4 method for giottoPoints
as.stars(x, drop = TRUE)
# S4 method for SpatVector
as.terra(x)
# S4 method for sf
as.terra(x)
# S4 method for stars
as.terra(x, type = c("vector", "raster"))
# S4 method for Spatial
as.terra(x)
# S4 method for giottoPolygon
as.terra(x, drop = TRUE)
# S4 method for giottoPoints
as.terra(x, drop = TRUE)
Arguments
- x
The object to coerce
- drop
When TRUE, returned object will be of the desired object type instead of wrapped in a
giottoPoints
orgiottoPolygon
object- type
whether data is 'vector' or 'raster'
See also
Other As coercion functions:
as.data.table()
,
as.points()
,
as.polygons()