View source: R/tensor_decomp.R
tensor_decomp | R Documentation |
Tucker: If there is no truncationin one of the modes, then this is the same as the MPCA,mpca. If there is no truncation in all the modes, then this is the same as the HOSVD,hosvd.
tensor_decomp(matrix, dims, method, xlabs = rownames(matrix),
ylabs = colnames(matrix)[-1], zlabs = NULL, ranks = A@modes,
savename = "TEST", plot = F)
matrix |
matrix that gets coverted to multidimensional array that get converted through as.tensor(arr) |
dims |
dimensions to fold the input matrix |
method |
"tucker" or "cp" |
plot |
plot heamtmaps of eigenvectors |
z_labs |
labels for the extra dimensions created, rows and colnames are the x and y axis labs |
rank |
default = 3, number (if CP) or vector of numbers (if tucker) that is <= the ranks of the tensor |
Input: Multidimensional array that gets converted to as.tensor Output: Decomposed tensor object
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.