procoteW {lazy.procrustes} R Documentation

## Expanded Orthogonal Procrustes Rotation

### Description

Expanded Orthogonal Procrustes Rotation

### Usage

```procoteW(A, C, estm = 0, estW = 0, minW = 0.001, T = NULL, W = NULL,
m = NULL, maxiter = 200, eps = 1e-06, print = 2)
```

### Arguments

 `A` The input matrix to be rotated `C` The target matrix `estm` = 1 to estimate m `estW` = 1 to estimate scalar W = 2 to estimate diagonal W `minW` minimum value of the elements of W `T` Initial value of T or NULL `W` Initial value of W or NULL `m` Initial value of m or NULL `maxiter` max # of iterations `eps` convergence criterion for rmse `print` = 1 to print result

### Details

This program finds those A, m, W and orthonormal T which minimize
RSS = tr( ( C - Chat )' ( C - Chat ) )
where Chat = A %*% W %*% T + matrix(1,nv) %*% t(m), W is a diagonal Matrix, T is an orthonormal rotation matrix,
m is the column mean vector.

Note that when estW=0 and estm=0, and the target matrix does not have missing elements,
this is equivalent to the usual orthogonal Procrustes rotation.

### Value

A list of:
B=A %*% W %*% T + matrix(1,nv,1)%*%t(m), T, W, , C the updated target matrix, rmse=sqrt(RSS)

### Examples

``` seed <- 1701; n <- 20; nr <- 2; pmiss <- 0; errstd <- 0.05
set.seed(seed)
resg <- gendataWmm( 1, n, nr, genm=1, genW=2, pmiss=pmiss, errstd=errstd)
A <- resg\$A
C <- resg\$C; Tg <- resg\$T; mg <- resg\$m; Wg <- resg\$W
res <- procoteW( A, C, estm=1, estW=2, print=1 )
T <- res\$T; m <- res\$m; W <- res\$W
Print( Tg-T, mg-m, Wg-W, fmt="7.3")

```

[Package lazy.procrustes version 0.1.3 Index]