[R] Data Cube in R from CSV

Ben Bolker bbolker at gmail.com
Sun Sep 19 17:58:39 CEST 2010


dajohnst <dajohnston <at> ucdavis.edu> writes:


> Why not use an array?
> 
> An array can be indexed in as many dimensions as you would like, and do not
> require any extra packages.  
> 
> x = array(1:27, dim = c(3, 3, 3))
> x
> x[1, , ]
> x[ , 1, ]
> x[ , , 1]
> 

  An array is certainly the right structure to hold a 'data cube' in R.
However, I think the original poster is looking for something similar
to View()  that would allow them to navigate interactively
through the rows, columns, and slices of a 3D array. I'm not aware of 
such an interface ...  If I were going to try to *develop* this I would
probably try to figure out how to use the tkTable widget 
<http://tktable.sourceforge.net/tktable/doc/tkTable.html>, but this
sounds like a non-trivial project ...



More information about the R-help mailing list