crandalf (version 0.0.1)

pkg_loadable: Whether a package is loadable

Description

This function is like require(), but it does not load the package in the current R session. Instead, it launches a new R session to test if a package is loadable. The reason for that is it is not trivial to remove all the side effects brought by library(), such as DLL's. Instead of cleaning up everything, we just use a new R session to test if a package is loadable.

Usage

pkg_loadable(p)

Arguments

p
the package name (must be of length 1)

Value

TRUE or FALSE.