utilityFunctions: Get the search path of an environment

getSearchPathR Documentation

Get the search path of an environment

Description

Returns a list with the environments or names of the environments on the search path. These functions are used for testing, use search instead.

Usage

getSearchPath(where = parent.frame())

getSearchPathNames(where = parent.frame())

getSearchPathContent(where = parent.frame())

getSearchPathDuplicates(where = parent.frame())

Arguments

where

(environment | module | function) the object for the search path should be investigated. If we supply a list with functions (e.g. a module), the environment of the first function in that list is used.

Examples

getSearchPath()
getSearchPathNames()
getSearchPathContent()

m <- module({
  export("foo")
  import("stats", "median")
  foo <- function() "foo"
  bar <- function() "bar"
})

getSearchPathContent(m)


modules documentation built on May 29, 2024, 2 a.m.