[Rd] RFC: What should ?foo do?

Duncan Murdoch murdoch at stats.uwo.ca
Fri Apr 25 00:45:31 CEST 2008

Currently ?foo does help("foo"), which looks for a man page with alias 
foo.  If foo happens to be a function call, it will do a bit more, so


will find the mean method for something if mean happens to be an S4 
generic.  There are also the type?foo variations, e.g. methods?foo, or 

I think these are all too limited.

The easiest search should be the most permissive.  Users should need to 
do extra work to limit their search to man pages, with exact matches, as 
? does.

We don't currently have a general purpose search for "foo", or something 
like it.  We come close with RSiteSearch, and so possibly ?foo should 
mean RSiteSearch("foo"), but
there are problems with that: it can't limit itself to the current 
version of R, and it doesn't work when you're offline (or when 
search.r-project.org is down.)  We also have help.search("foo"), but it 
is too limited. I'd like to have a local search that looks through the 
man pages, manuals, FAQs, vignettes, DESCRIPTION files, etc., specific 
to the current R installation, and I think ? should be attached to that 

Comments, please.

Duncan Murdoch

More information about the R-devel mailing list