R/rxReq.R

Defines functions rxReq

Documented in rxReq

#' Require namespace, otherwise throw error.
#'
#' @param pkg Package required for function to work.
#' @return Nothing
#' @author Matthew L. Fidler
#' @export
#' @keywords internal
rxReq <- function(pkg) {
  ## nocov start
  if (!requireNamespace(pkg, quietly = TRUE)) {
    stop(sprintf(gettext("package \"%s\" needed for this function to work"), pkg),
      call. = FALSE
    )
  }
  ## nocov end
}

Try the rxode2et package in your browser

Any scripts or data that you put into this service are public.

rxode2et documentation built on June 22, 2024, 12:17 p.m.