powered by
Simulates a n x q genetic matrix with the option to specify the common pairwise correlation.
sim_gmat(n,q,rho)
The result of a n x q genetic matrix of q SNPs.
Total number of observations.
Total number of SNPs.
Common pairwise correlation parameter.
# Set sample size n = 100 # Set number of SNPs q = 5 # Set common pairwise correlation rho = 0.1 # Simulate genetic matrix gMat <- sim_gmat(n, q, rho)
Run the code above in your browser using DataLab