as.Tensor | R Documentation |
This will converts array to S3 object tensor. Vectors and matrices must first be converted to an array before applying as.Tensor.
as.Tensor(t)
t |
Numeric, array of numbers |
S3 class tensor
Kyle Caudle
Randy Hoover
Jackson Cates
Everett Sandbo
indices <- c(2,3,4)
arr <- array(runif(prod(indices)), dim = indices)
arrT <- as.Tensor(arr); arrT
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.