For the RScript transform, a huge number of packages are available for various domains in statistical analysis. To use a package inside of an RScript transform, you must download and install it in R first.
To perform an R installation of External Packages, follow these steps:
install.packages()in the R console.
- Choose a CRAN repository.
- Choose the package that will be installed.
Note: by default, R tries to install the libraries to the directory:
<R Installation directory>/library.
- If you get an error message on insufficient authorizations, start the R console as an administrator.
Don’t use a personal library for the R packages. Depending on your authorizations, it might be that Jedox Integrator doesn’t have access to this directory. As an alternative, you can also use a different directory for the libraries by setting the environment variable
R_LIBS to point to this directory.
In RScript Transform, these packages have to be declared with their name in the table “External Packages”. This generates the following R command for each package which is processed before the RScript transform:
suppressPackageStartupMessages (require (<<i>name of package></i><i>))