Casts an object with class tensor to an R atomic vector, matrix or array.
# S3 method for tensor
as.array(x)
Arguments
x |
tensor object to be casted to an R array. |
See also
Examples
#> , , 1
#>
#> [,1] [,2]
#> [1,] 1 3
#> [2,] 2 4
#>
#> , , 2
#>
#> [,1] [,2]
#> [1,] 5 7
#> [2,] 6 8
#>