search for: dimnmx

Displaying 1 result from an estimated 1 matches for "dimnmx".

Did you mean: dimnmy
2008 Aug 08
1
operating on arrays of unknown dimensionality
...slices of arrays where dimensionality of the array is not a-priory known. Specifically, I would like to be able to generalize the following example of dimensionality 2 to an arbitrary diminsionality: In this example we create an array x, a smaller array y and then assign y to a slice of x. > dimnmx <- list(c('a','b'), c('x','y','z')); x <- array(0, dim=sapply(dimnmx, length), dimnames=dimnmx) > x x y z a 0 0 0 b 0 0 0 > dimnmy <- list(c('a','b'), c('x','z')); y <- array(1, dim=sapply(dimnmy, length), d...