Skip to content

Loading R packages when versions are not synchronisedΒΆ

Question

I tried installing a package in R/Rstudio, but I am unable to do so as it tells me it cannot find the package:

Warning in install.packages :

cannot open URL `<URL>` : HTTP status was '404 Not Found'

For example, here we try to install the reticulate package, and it gives a message that version 1.15 cannot be found.

Can I do something about this?

Answer

In most cases you are able to resolve this by following these steps.

Step 1) Within the Research Environment, open the Firefox Browser. Go to "https://artifactory.gel.zone/artifactory/cran/src/contrib/". This will show a list of all the potential packages and versions available for install. If we try to find the reticulate package (Ctrl+F, and type "reticulate"), we can see that it has version 1.16 in its name. This difference in expected and observed version is what causes the failed installations.

Step 2) Now that we know which version the reticulate package should be, we can directly load it using the specific address. Within R/Rstudio, just type the following:

install.packages("https://artifactory.gel.zone/artifactory/cran/src/contrib/reticulate_1.16.tar.gz", repos = NULL, type = "source") and press enter. This should start the installation of the package, and at the end you can load your library as usual with library("reticulate").

In case the steps above do not help resolve your issue, please submit a ticket to our service desk so we can help resolve the issue.

Last updated

This page was last updated on the 12 Jun 2020.