Skip to contents

dbSpatial Package

Functions and methods for dbSpatial objects

as_dbSpatial()
Convert an sf or terra object to a dbSpatial object
dbSpatial()
Create a dbSpatial object with geometry data type
show(<dbSpatial>)
show method for dbSpatial

Spatial Joins

Functions and methods that perform a spatial join between dbSpatial objects.

st_contains()
Determine if geometries in two dbSpatial objects contain each other
st_coveredby()
Determine if geometries in two dbSpatial objects are covered by each other
st_covers()
Determine if geometries in two dbSpatial objects cover each other
st_crosses()
Determine if geometries in two dbSpatial objects cross each other
st_difference()
Calculate the difference between geometries in two dbSpatial objects
st_disjoint()
Determine if geometries in two dbSpatial objects are disjoint
st_distance()
Calculate the distance between geometries in two dbSpatial objects
st_equals()
Determine if geometries in two dbSpatial objects are equal
st_intersects()
Determine if geometries between two dbSpatial objects are intersecting
st_touches()
Determine if geometries in two dbSpatial objects touch each other

Spatial Summary

Functions and methods that summarize geometry data in a dbSpatial object.

st_extent()
Get extent of a geometry column in dbSpatial object
st_xmax()
Get maximum x coordinate
st_ymax()
Get maximum y coordinate

Spatial Properties

Functions and methods that return a single vector about a geometry in a dbSpatial object.

st_geometrytype()
Return geometry type
st_isvalid()
Determine if geometry is valid

Geometry construction

Functions and methods for constructing or modifying geometry in a dbSpatial object.

st_translate()
Translate x, y coordinates by delta x, delta y for point geometries

DuckDB Spatial Extension

Functions and methods specific for DuckDB spatial extension.

loadSpatial()
Install and/or load DuckDB spatial extension

dbData

dbData methods

head(<dbSpatial>)
head method for dbSpatial
`[`(<dbSpatial>,<missing>,<missing>,<missing>) `[<-`(<dbSpatial>,<ANY>,<ANY>,<ANY>)
Extract method for dbSpatial
tail(<dbSpatial>)
tail method for dbSpatial