mt_aeqd_crs {move2}R Documentation

Create a AEQD coordinate reference system

Description

The CRS can be centered around the centroid or center of a move2 object or a reference location

Usage

mt_aeqd_crs(x, center = c("centroid", "center"), units = c("m", "km"))

Arguments

x

An object of the class sf or sfc, for example a move2 to determine the center from. This argument is only required if center is a character.

center

Either the method to identify the coordinates of the center of x or the center as a numeric, POINT or a sf/sfc of length 1. "centroid" calculates the centroid of a collection of points while "center" calculates the center from the range of the locations.

units

The units of the AEQD projection either m or km for meter or kilometer respectively

Value

An object of the class crs that can for example be used for re projecting

Examples

mt_aeqd_crs(center = c(10, 45))
mt_aeqd_crs(center = sf::st_point(c(10, 45)), units = "km")

m <- mt_read(mt_example())
mt_aeqd_crs(center = sf::st_geometry(m)[5])
mt_aeqd_crs(m)
aeqd_crs <- mt_aeqd_crs(m, "center", "km")
aeqd_crs
sf::st_transform(m, aeqd_crs)


[Package move2 version 0.3.0 Index]