| bc_dim | R Documentation |
bc_dim(x, y) gives the dimensions an array would have,
as the result of an broadcasted binary element-wise operation between 2 arrays
x and y.
bc_dim(x, y)
x, y |
an atomic or recursive array. |
Returns an integer vector giving the broadcasted dimension sizes of the result,
or the length of the result if its dimensions will be NULL.
x.dim <- c(4:2)
x.len <- prod(x.dim)
x.data <- sample(c(TRUE, FALSE, NA), x.len, TRUE)
x <- array(x.data, x.dim)
y <- array(1:50, c(4,1,1))
dim(bc.b(x, y, "&")) == bc_dim(x, y)
dim(bc.b(x, y, "|")) == bc_dim(x, y)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.