T3funcrep {ThreeWay}R Documentation

Algorithm for the Tucker3 model

Description

Alternating Least Squares algorithm for the minimization of the Tucker3 loss function.

Usage

 T3funcrep(X, n, m, p, r1, r2, r3, start, conv, A, B, C, H) 
 

Arguments

X

Matrix (or data.frame coerced to a matrix) of order (n x mp) containing the matricized array (frontal slices)

n

Number of A-mode entities

m

Number of B-mode entities

p

Number of C-mode entities

r1

Number of extracted components for the A-mode

r2

Number of extracted components for the B-mode

r3

Number of extracted components for the C-mode

start

Starting point (0 starting point of the algorithm from generalized eigenvalue decomposition, 1 random starting point (orthonormalized component matrices), 2 if users specified component matrices

conv

Convergence criterion

A

Optional (necessary if start=2) starting value for A

B

Optional (necessary if start=2) starting value for B

C

Optional (necessary if start=2) starting value for C

H

Optional (necessary if start=2) starting value for the matricized core array (frontal slices)

Value

A list including the following components:

A

Orthonormal component matrix for the A-mode

B

Orthonormal component matrix for the B-mode

C

Orthonormal component matrix for the C-mode

H

Matricized core array (frontal slices)

f

Loss function value

fp

Fit percentage

iter

Number of iterations

cputime

Computation time

La

Matrix which should be diagonal, and if so, contain ‘intrinsic eigenvalues’ for A-mode

Lb

Matrix which should be diagonal, and if so, contain ‘intrinsic eigenvalues’ for B-mode

Lc

Matrix which should be diagonal, and if so, contain ‘intrinsic eigenvalues’ for C-mode

Note

The loss function to be minimized is ||X_A - A G_A kron(C',B')||^2 where X_A and G_A denote the matricized (frontal slices) data array and core array, respectively, and kron stands for the Kronecker product.
T3funcrep is the same as T3func except that all printings are suppressed. Thus, T3funcrep can be helpful for simulation experiments.

Author(s)

Maria Antonietta Del Ferraro mariaantonietta.delferraro@yahoo.it
Henk A.L. Kiers h.a.l.kiers@rug.nl
Paolo Giordani paolo.giordani@uniroma1.it

References

H.A.L. Kiers, P.M. Kroonenberg \& J.M.F. ten Berge (1992). An efficient algorithm for TUCKALS3 on data with large numbers of observation units. Psychometrika 57:415–422.
P.M. Kroonenberg \& J. de Leeuw (1980). Principal component analysis of three-mode data by means of alternating least squares algorithms. Psychometrika 45:69–97.

See Also

T3, T3func

Examples

data(Bus)
# labels for Bus data
laba <- rownames(Bus)
labb <- substr(colnames(Bus)[1:5], 1, 1)
labc <- substr(colnames(Bus)[seq(1,ncol(Bus),5)], 3, 8)
# T3 solution using two components for all the modes 
# (rational starting point by SVD [start=0])
BusT3 <- T3funcrep(Bus, 7, 5, 37, 2, 2, 2, 0, 1e-6)
# T3 solution using two components for all the modes 
# (random orthonormalized starting point [start=1])
BusT3 <- T3funcrep(Bus, 7, 5, 37, 2, 2, 2, 1, 1e-6)
# T3 solution using two components for all the modes 
# (user starting point [start=2])
BusT3 <- T3funcrep(Bus, 7, 5, 37, 2, 2, 2, 1, 1e-6, matrix(rnorm(7*2),nrow=7), 
 matrix(rnorm(5*2),nrow=5), matrix(rnorm(37*2),nrow=37), 
 matrix(rnorm(2*4),nrow=2))

[Package ThreeWay version 1.1.3 Index]