This function produces barplots representative of the contribution of a particular trait or variable to either a discriminant function or principle component axis.
Loadings(DATA, GROUPS, method = c("PCA", "LDA"))
Outputs a list with values and plots for each test listed in method.
A (non-empty) numeric matrix with trait values
A (non-empty)factor vector indicating the group membership of each row in DATA
An optional list indicating whether the results for a principle component analysis, 'PCA', or linear discriminant analysis, 'LDA' should be performed.
pca
, lda
data(Nuclei)
data(Groups)
Loadings(Nuclei, Groups, method=c("PCA", "LDA"))
Run the code above in your browser using DataLab