bschilder / ThreeWayTest

Summary statistics-based association test for identifying the pleiotropic effects with set of genetic variants

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Improve function efficiency

bschilder opened this issue · comments

Some key ways to generally improve the efficiency of your code:

  • Use lapply or Reduce instead of for loops where possible.
  • Use data.tables instead of data.frames and take advantage of their speedy vectorized transformations.
  • Consider parallelizing steps across multiple cores for speed boosts (e.g. via the parallel package). I'll leave it to you to decide whether (and where) you'd like to implement this.