cc {CCA} | R Documentation |
The function performs Canonical Correlation Analysis to highlight correlations between
two data matrices. It complete the cancor()
function with supplemental numerical and
graphical outputs and can handle missing values.
cc(X, Y)
X |
numeric matrix (n * p), containing the X coordinates. |
Y |
numeric matrix (n * q), containing the Y coordinates. |
The canonical correlation analysis seeks linear combinations of the 'X' variables which are the most correlated with linear combinations of the 'Y' variables.
Let PX and PY be the projector onto the respective column-space of X and Y. The eigenanalysis of PXPY provide the canonical correlations (square roots of the eigenvalues) and the coefficients of linear combinations that define the canonical variates (eigen vectors).
A list containing the following components:
cor |
canonical correlations |
names |
a list containing the names to be used for individuals and variables for graphical outputs |
xcoef |
estimated coefficients for the 'X' variables as returned by |
ycoef |
estimated coefficients for the 'Y' variables as returned by |
scores |
a list returned by the internal function |
Sébastien Déjean, Ignacio González
www.lsp.ups-tlse.fr/CCA
data(nutrimouse) X=as.matrix(nutrimouse$gene[,1:10]) Y=as.matrix(nutrimouse$lipid) res.cc=cc(X,Y) plot(res.cc$cor,type="b") plt.cc(res.cc)