Generate a correlation matrix as R = LL' where the rows of L are of length
1, L is of rank r
and the matrix L is sparse (depending on
sparse.prop
. The loadings in L are sampled from a standard normal
distribution, after which sparse.prop
is used to set a randomly
chosen number of loadings in each row equal to zero. To ensure that a
correlation matrix results, the rows are normalized.