Friday 12 May 2017

R Namespace

Cited from the book "Extending R"

Once a package has been loaded into the R process, the corresponding namespace is an object (an "environment") containing all the objects from that package

To extract the namespace of a package

ns <- asNamespace([package name])

Use str(ns$'function name') to see the structure of a named function within a package.

No comments:

Post a Comment