entry.value | R Documentation |
entry.value
retrieves or sets the values in an array a
at the
positions indicated by the rows of a matrix idx
.
entry.value(a, idx)
a |
An array. |
idx |
Numerical matrix with the same number of columns as the number
of dimensions of |
value |
An array of length |
entry.value(a,idx)
returns a vector of values at the
indicated cells. entry.value(a,idx) <- val
changes the indicated
cells of a
to val
.
Raoul Grasman
a = array(1:(4^4),c(4,4,4,4))
entry.value(a,cbind(1:4,1:4,1:4,1:4))
entry.value(a,cbind(1:4,1:4,1:4,1:4)) <- 0
entry.value(a, as.matrix(expand.grid(1:4,1:4,1:4,1:4)))
# same as `c(a[1:4,1:4,1:4,1:4])' which is same as `c(a)'
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.