Skip to contents

Rotate vector object to position that eigenvectors are parallel to axes of coordinate system: E3||X (north-south), E2||X(east-west), E1||X(vertical)

Usage

center(x, max_vertical = FALSE)

Arguments

x

numeric. Can be three element vector, three column array, or an object of class "line" or "plane"

max_vertical

Whether the maximum of the von Mises-Fisher distribution is already vertical or not.

Value

Object of class of x

See also

Examples

set.seed(1)
mu <- Line(120, 50)
x <- rvmf(100, mu = mu, k = 20)
x_centered <- center(x)
stereoplot()
stereo_point(x, col = "grey")
# stereo_point(mu, col = "red")
stereo_point(x_centered, col = "black")
stereo_point(Line(c(0, 90, 180), c(0, 0, 90)), col = 2:4, lab = c("E3", "E2", "E1"))