Support

FAQ for RStudio Public Package Manager

Follow

RStudio Public Package Manager is a hosted instance of RStudio Package Manager for community use. RStudio Public Package Manager provides a CRAN repository and Bioconductor repository with features such as:

  • Precompiled binary packages for faster installations on Linux and Windows (CRAN packages only)
  • Repository checkpoints for reproducibility across time
  • System dependency information for R packages

RStudio does not provide professional support for RStudio Public Package Manager. If you need help, the best place to ask questions is RStudio Community. If you're reporting a problem, please create a topic using this template and provide as much information as you can.

 

How do I install packages from RStudio Public Package Manager?

Navigate to the Setup page and follow the instructions to configure R or RStudio to use packages from packagemanager.rstudio.com.

To install binary packages, click the Binary button and select a Client OS to get the binary repository URL for your operating system. Binary packages are available on Linux and Windows for R 3.4 and above.

Note that your R environment may require additional configuration steps to use binary packages from RStudio Package Manager, particularly on Linux. Consult the documentation for Configuring R on Linux or Configuring R on Windows to learn more.

When installing binary packages on Linux, you should see a message like this in your R console:

> install.packages("ggplot2")
...
* installing *binary* package ‘ggplot2’ ... 

On Windows, you should instead see a message like:

> install.packages("ggplot2")
...
package ‘ggplot2’ successfully unpacked and MD5 sums checked

The downloaded binary packages are in
    C:\Users\user\AppData\Local\Temp\RtmpiswaaW\downloaded_packages

 

How do I troubleshoot package installation issues?

Received source package from a binary repository URL

When installing packages from a binary repository URL, you may receive a source package instead of a binary package. When this happens, a message like this will appear in your R console:

> install.packages("RPostgreSQL")
...
* installing *source* package ‘RPostgreSQL’ ... 

In interactive R sessions on Windows, you may also see the following prompt:

> install.packages("dplyr")
Package which is only available in source form, and may need
  compilation of C/C++/Fortran: 'dplyr'
Do you want to attempt to install these from sources? (Yes/no/cancel)

Check that you have the correct binary repository URL for your operating system, and that you have met the prerequisites for using binary packages (see How do I install packages? above).

Otherwise, binaries may be unavailable for that package. RStudio Package Manager does not provide binaries for all CRAN packages. Notable exclusions include any CRAN packages with Bioconductor dependencies, such as Seurat or WGCNA.

Error loading binary package in R

You may see one of the following errors when loading binary packages in R:

> library(rJava)
Error: package or namespace load failed for 'rJava':
.onLoad failed in loadNamespace() for 'rJava', details:
call: dyn.load(file, DLLpath = DLLpath, ...)
error: unable to load shared object '/opt/R/3.6.3/lib/R/library/rJava/libs/rJava.so':
libjvm.so: cannot open shared object file: No such file or directory
> library(sf)
Error: package or namespace load failed for 'sf' in dyn.load(file, DLLpath = DLLpath, ...):
unable to load shared object '/opt/R/3.6.3/lib/R/library/units/libs/units.so':
libudunits2.so.0: cannot open shared object file: No such file or directory
> library(Rcpp)
Error: package or namespace load failed for ‘Rcpp’ in dyn.load(file, DLLpath = DLLpath, ...):
 unable to load shared object '/opt/R/3.6.3/lib/R/library/Rcpp/libs/Rcpp.so':
 /lib64/libstdc++.so.6: version `GLIBCXX_3.4.20' not found (required by /opt/R/3.6.3/lib/R/library/Rcpp/libs/Rcpp.so)

Check that you have the correct binary repository URL for your operating system, and that you have met the prerequisites for using binary packages (see How do I install packages? above).

The most common issue is that your system is missing additional system dependencies that the package requires. To determine if a package requires additional system dependencies, search for the package in the RStudio Package Manager web interface, and check the list of system prerequisites for your operating system. For example:

https://packagemanager.rstudio.com/client/#/repos/1/packages/httr

System dependency installation commands for the httr package on Ubuntu 16.04

If you still see an error after installing the system prerequisites, please report the issue at RStudio Community and provide as much information as you can, including your R version and operating system.

 

Why is the newest package version from CRAN or Bioconductor not available yet? 

We evaluate CRAN and Bioconductor each business day (Monday through Friday) and publish new snapshots when updates are available. Then, RStudio Public Package Manager syncs these snapshots daily. For example, suppose a CRAN package gets updated on Saturday. We will publish a new snapshot to the RStudio Package Service sometime on Monday, usually Monday afternoon. Then, the CRAN sync will pick up the change on Tuesday at 12:00am. Occasionally, if there are very important updates, we generate an extra snapshot to make the updates available sooner. The timing of each snapshot varies based on the number of changes and the number of dependencies involved.

Comments