Learn R Programming

box (version 1.1.0)

find_in_path: Find a module<U+2019>s source location

Description

Find a module<U+2019>s source location

Usage

find_in_path(spec, base_paths)

Arguments

spec

a mod_spec.

base_paths

a character vector of paths to search the module in, in order of preference.

Value

find_in_path returns a mod_info that specifies the module source location.

Details

A module is physically represented in the file system either by <U+2039>spec_name(spec)<U+203A>.r or by <U+2039>spec_name(spec)<U+203A>/__init__.r, in that order of preference in case both exist. File extensions are case insensitive to allow for R<U+2019>s obsession with capital-R extensions (but lower-case are given preference, and upper-case file extensions are discouraged).