Meaning of common message when install a package "There are binary versions available but the source versions are later"


#1

When installing packages, the message There are binary versions available but the source versions are later often appears. This is (I think) followed by the question Do you want to install from sources the package which needs compilation?.

What does the message mean? And what response (y or n) is recommended and in what situations?


#2

This often means that the package has updated recently on CRAN but the binary isn’t yet available for your OS (can take a day or two). There are probably other scenarios when the binary isn’t available for your platform.

If you say no, you won’t get the most recent version. But this might be just fine, unless you were specifically installing because of an update.

If you say yes, the package will be built from source locally. If it has compiled code and you’ve never set up build tools for R, then this won’t actually succeed.


#3

Is there an option in install.packes() in order to say yes and avoid the necessity for the user to type something interactively?