# How to simulate random correlation matrix containing off diagonal structures

I want to simulate a correlation matrix which has some off-diagonal structures and also should have some hierarchical structures. For simulating correlation matrices which contain hierarchical structures, I am using this paper. But, I don't know how to add off-diagonal structures to it. I want to simulate a correlation matrix which somewhat have off-diagonal structures as below image

An example of a hierarchical structure in the correlation matrix is below image

Does anyone have a suggestion on how to simulate such correlation matrices?

• Dunno if this is helpful, but with mvnorm in R you can generate data for whatever correlation matrix you want. But I'm guessing you don't want to sit there typing out each individual element in that matrix. Oh well, hope this helps a little anyway. – Huy Pham Nov 24 '18 at 12:21
• Possible duplicate of Simulate correlation matrix using a given structure – Xi'an Nov 28 '18 at 5:07
• If you can translate "hierarchical structure" to "eigenvalue structure" (clumpiness), see scipy.stats.random_correlation. Or, generate R' Λ R with random orthonormal R in a language of your choice. – denis May 22 at 10:34