[R] names of functions in a library

Duncan Murdoch murdoch at stats.uwo.ca
Mon Jun 6 22:55:11 CEST 2005


On 6/6/2005 4:43 PM, Omar Lakkis wrote:
> How can I get a list of the names of all exported functions in a library?
> I load my library using library() and then want to dynamically get all
> functions that start with "test."  to dynamically execute them.

Use search() to see all the _packages_ that have been loaded.  If yours 
is second in the list (the typical spot just after calling the 
unfortunately named library() function), then ls(2) will list all of its 
exports.

Duncan Murdoch




More information about the R-help mailing list