psych (version 1.0-17)

VSS.scree: Plot a scree test

Description

Cattell's scree test is one of most simple ways of testing the number of components in a correlation matrix. Here we plot the eigen values of a correlation matrix.

Usage

VSS.scree(rx, main = "scree plot")

Arguments

rx
a correlation matrix or a data matrix. If data, then correlations are found using pairwise deletions.
main
Title

References

http://personality-project.org/r/vss.html

See Also

VSS.plot, ICLUST, omega

Examples

Run this code
#VSS.scree(attitude)
#VSS.scree(cor(attitude)

## The function is currently defined as

function(rx,main="scree plot") {
 nvar <- dim(rx)[2]
 if (nvar <dim(rx)[1]) {rx <- cor(rx,use="pairwise")}
 princ <- principal(rx,nvar)
plot(princ$values,type="b", main = main )
abline(h=1) }

Run the code above in your browser using DataLab