ghm17 / LOGODetect

LOGODetect is a powerful tool to identify small segments that harbor local genetic correlation between two traits/diseases.
GNU General Public License v3.0
23 stars 5 forks source link

Remove unused argument mu #4

Closed jdblischak closed 3 years ago

jdblischak commented 3 years ago

The function rmv() has an argument mu that appears to be unused:

https://github.com/ghm17/LOGODetect/blob/61e39cbc04d69b2bb354672529673a10fcdbb6ac/Code/random_vector_generation.R#L41-L50

A long vector of zeros is passed to mu (the same length as the dimensions of Sigma), and I did a quick test to convince myself that the argument had no effect:

> set.seed(1)
> ss1 = rmv(3*N, rep(0, len[1]), ld_diag[[1]])
> set.seed(1)
> ss2 = rmv(3*N, Sigma = ld_diag[[1]])
> identical(ss1, ss2)
[1] TRUE

This PR removes the unused argument mu and updates the calls rmv() to remove the vector of zeros.

ghm17 commented 3 years ago

@jdblischak Yes, mu is needless in function rmv. Thanks for your suggestive comment.