rotate2D: Rotate a plane of coordinates

Description Usage Arguments Value Author(s) Examples

View source: R/rotate2D.R

Description

Rotate a plane of coordinates to a given angle.

Usage

1
rotate2D(plane, angle, threads = 1)

Arguments

plane

A data.table with two columns describing the plane of coordinates.

angle

A numeric vector describing the degrees of rotation.

threads

An integer specifying the number of threads to use. Experiment to see what works best for your data on your hardware.

Value

A data.table with the rotation applied to plane.

Author(s)

J. Antonio Guzmán Q.

Examples

1
2
3
4
5
6
data(pc_tree)

plot(pc_tree[,1:2])

#Rotate in 45 degrees using Z axis of the cloud
plot(rotate2D(pc_tree[,1:2], angle = 45))

Antguz/rTLS documentation built on Dec. 14, 2021, 9:49 a.m.