find_calling_functions {lazy.tools}R Documentation

Find Calling Functions

Description

Find Calling Functions

Usage

find_calling_functions(
  func = NULL,
  resff = NULL,
  from = NULL,
  nonative = 1,
  noglobal = 0,
  packages = NULL,
  print = 1
)

Arguments

func

A function object (no quote) or a list/vector of the function object names to be searched.

resff

The result of find_functions from which func will be searched.

from

A name of a function or a list of functions from which func will be searched. (resff has priority over from.)

nonative

: argument of find_functions

noglobal

: argument of find_functions

packages

: argument of find_functions

print

= 0 not to print the result.

Details


When resff is not given, this function requires "codetools" package.

This function matches each element of func to the elements of resff.
resff can be created as
resff <- find_functions( from, nonative=nonative, unlist=0 , noglobal=noglobal, packages=packages )

Value

A list of:
res The list of function names which contains each of func.
resff The reslt of find_functions.

Examples

## Not run: 
library(codetools)
library(lazy.tools)

res=find_calling_functions( vartype, from=ls("package:lazy.tools") )
res2=find_calling_functions( c("vartype","varlist"), resff=res$resff )$res
# res2 can be obtained by
#  find_calling_functions( c("vartype","varlist")
#                        , from=ls("package:lazy.tools") )$res
# but find_function takes long time.

## End(Not run)


[Package lazy.tools version 0.1.4 ]