R/size.R
rray_size.Rd
rray_size() returns the total number of elements in an array, computed as the product of its dimensions.
rray_size()
rray_size(x)
An array.
A single double representing the total number of elements.
rray_size(1:5) #> [1] 5 rray_size(array(1, c(2, 3))) #> [1] 6 rray_size(array(1, c(2, 3, 4))) #> [1] 24