View source: R/rotate_coords.R
rotate_coords | R Documentation |
Applies a 3x3 rotation matrix to a set of 3D coordinates.
rotate_coords(x, y, z, rotation_matrix)
x |
y, z Numeric vectors of equal length representing 3D coordinates. |
rotation_matrix |
A 3x3 numeric matrix used to rotate the coordinates. |
A data frame with rotated coordinates ('x', 'y', 'z').
rot_mat <- create_rotation_matrix(90, "z")
rotate_coords(1, 0, 0, rot_mat)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.