Skip to content
Prev 97043 / 398500 Next

question about dataframe ("sensory") in PLS package

Try:

?sensory
str(sensory)
dput(sensory)
lapply(sensory, class)
lapply(sensory, dim)

to see what it looks like inside.  Seems that sensory is a data frame
consisting of two columns each of which is a matrix except that each
has a class of "AsIs".  Thus try this (where I(...) creates objects of
class "AsIs"):

mat1 <- cbind(a = 1:5, b = 11:15)
mat2 <- cbind(x = 21:25, y = 31:35)
DF <- data.frame(A = I(mat1), B = I(mat2))
On 7/30/06, jz7 at duke.edu <jz7 at duke.edu> wrote: