Reputation: 99536
Is it possible to install a package without installing dependencies?
When run the following command:
install.packages("package",dependencies=FALSE)
if the dependencies are not installed beforehand, isn't it that the installation of the package fails?
My question comes from this post Install a local R package with dependencies from CRAN mirror. Why does it say installing a local package without installing dependencies?
if I set repos=NULL it correctly tries to install the local package file (as documented), but obviously it does not find the dependencies packages.
Thanks!
Upvotes: 13
Views: 12553
Reputation: 206536
You cannot install and get a package to work without its dependencies. The dependencies=
parameter is really an indicator if you would like R to automatically install the dependencies. If set to FALSE, R still stop and warn you so you can decide what you would like to do; if TRUE, R will automatically try to download from your current CRAN repository mirror. With repos=NULL
(a local file install) there is nowhere else to look for dependencies so the dependencies=
parameter is ignored.
Upvotes: 15