| create_pop | R Documentation | 
The correlation will be exactly the one specified. The used method is described here: https://stats.stackexchange.com/questions/15011/generate-a-random-variable-with-a-defined-correlation-to-an-existing-variables/15040#15040
create_pop(rho, size)
| rho | Population correlation. | 
| size | Population size. | 
Two-dimensional population matrix with a specific correlation.
pop <- create_pop(rho = 0.5, size = 1e6) cor(pop)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.