Threshold correlation matrix to match a given number of edges.
cor2adj(R, n)
R
correlation matrix.
n
number of edges.
A thresholded matrix.