Hello, I do this in such way:
DATAX - matrix(seq(1,6,1),2,3)
DATAY - matrix (seq(1,4,1),2,2)
rownames(DATAX) - c(s1,s2)
rownames(DATAY) - c(s1,s2)
colnames (DATAX) - c(v1,v2,v3)
colnames (DATAY) - c(respone_1,response_2)
KAL - data.frame (N = rownames(DATAX))
KAL$Y - DATAY
KAL$X - DATAX
KAL$X
Dear all,
I am trying to my dataframe for the PLS analysis using the PLS package.
However I have some trouble generating the correct dataframe. The main
problem is how to use one name to represent several columns in the
dataframe.
The example dataframe in PLS package is called sensory. I cannot
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