r - name headers of all dimensions in an array (dim>2) -


i name "levels" or "sections" or "layers" of 3-dimensional array!


is there way this? clarify: levels mean rows of 3d matrix, when rotated in 2nd dimension. found similar question, nevertheless doesn't cover specific aspect. answer @spacedman. anyway, want have additional header third dimension:

numb.x <- sample(99, 80) my.array <- array(numb.x, dim = c(5,4,3), dimnames = c("row","col","lev")) rownames(my.array)<-c("ri","rj","rk","rl","rm") colnames(my.array)<-c("cn","cm","co","cp") my.array[,,1] my.array[,1,] 

so, how can headers last section of array (previous line of code)using vector of names provided below?

levs <- c("lx","ly","lz") 


Comments

Popular posts from this blog

sublimetext3 - what keyboard shortcut is to comment/uncomment for this script tag in sublime -

java - No use of nillable="0" in SOAP Webservice -

ubuntu - Laravel 5.2 quickstart guide gives Not Found Error -