powered by
Parallel Factor Analysis
parafac( Tensor, nfac, nstart = 1, maxit = 500, ctol = 1e-04, initialization = "random", output = "best", sortComponents = FALSE )
List object of the PARAFAC model or models.
3-way matrix of numeric data
Number of factors (components) to fit.
Number of models to randomly initialize (default 1).
Maximum number of iterations allowed without convergence (default 500).
Relative change in loss tolerated to call the algorithm converged in the ALS case (default 1e-4).
"Random" for randomly initialized input vectors or "nvec" for svd-based best guess.
String ("best"/"all") Return only the best model of the nstart models ("best") or return all of them in a list object ("all").
Boolean to sort the components based on their variance explained (default FALSE)
X = array(rnorm(108*100*10), c(108,100,10)) model = parafac(X, 2)
Run the code above in your browser using DataLab