| procrustes {bigutilsr} | R Documentation | 
Procrustes transform
Description
Procrustes transform Y = pXR (after centering), where p is a scaling coefficient and R is a rotation matrix that minimize ||Y - pXR||_F.
Usage
procrustes(Y, X, n_iter_max = 1000, epsilon_min = 1e-07)
Arguments
| Y | Reference matrix. | 
| X | Matrix to transform ( | 
| n_iter_max | Maximum number of iterations. Default is  | 
| epsilon_min | Convergence criterion. Default is  | 
Value
Object of class "procrustes", a list with the following elements:
-  $R: the rotation matrix to apply toX,
-  $rho: the scaling coefficient to apply toX,
-  $c: the column centering to apply to the resulting matrix,
-  $diff: the average difference betweenYandXtransformed.
You can use method predict() to apply this transformation to other data.
Examples
A <- matrix(rnorm(200), ncol = 20)
B <- matrix(rnorm(length(A)), nrow = nrow(A))
proc <- procrustes(B, A)
str(proc)
plot(B, predict(proc, A)); abline(0, 1, col = "red")
[Package bigutilsr version 0.3.4 Index]