By Julia Piaskowski
Sources Thomas Lumley, Github repo useRfasteR Hadley Wickham, Profiling, Advanced R Dirk Eddelbuettel, Rcpp
The Process for Improving Code: (quote from Advanced R)
Find the biggest bottleneck (the slowest part of your code).
Try to eliminate it (you may not succeed but that's ok).