Learn R Programming

sig (version 0.0-6)

list_sigs: List the signatures of all functions

Description

Lists the signatures of all functions in an environment or file.

Usage

list_sigs(x, pattern = NULL, ...)

# S3 method for default list_sigs(x, pattern = NULL, ...)

# S3 method for sig list_sigs(x, pattern = NULL, ...)

# S3 method for character list_sigs(x, pattern = NULL, ...)

Arguments

x

An environment or the the path to a file.

pattern

An optional regular expression. Only names matching pattern are returned.

...

Currently ignored

Value

An object of class siglist, which is a list of sig objects.

Examples

Run this code
# NOT RUN {
#From a package
list_sigs(pkg2env(graphics))
#Just functions beginning with 'a'.
list_sigs(pkg2env(graphics), pattern = "^a")
#From a file
list_sigs(system.file("extdata", "sample.R", package = "sig"))
# }

Run the code above in your browser using DataLab