Workarounds that I've used:
- Install binary versions of packages
- Cache between sessions
- Avoid
dplyr if compile time is critical
On the latter point, there have been occasions where I've used a package for it's runtime performance and then been bitten by its install time. For example, for a particular project I chose readr::read_lines as it's much faster (at least in R < 3.5) than base R's readLines. However, the install time for readr gobbled up any savings for my purposes, so I switched back to readLines. Similarly, for dplyr, you may be better off using base R functions: it's harder, but obviously possible, and in your case it may be that the extra programming time is worth it.