has_pkg: Check whether an optional package is installed

View source: R/utils.R

has_pkgR Documentation

Check whether an optional package is installed

Description

Emits an informative message() (not an error) if the package is missing, so that the caller can skip optional functionality gracefully.

Usage

has_pkg(pkg, feature = NULL)

Arguments

pkg

Package name as a character string.

feature

Short description of what requires the package (for message).

Value

Logical TRUE if available, FALSE otherwise.


FitVerse documentation built on Dec. 1, 2026, 1:07 a.m.