Skip to content

Using help()

7 messages · Michael Kubovy, Rolf Turner, Brian Ripley +3 more

#
On 25/01/2009, at 2:33 PM, Michael Kubovy wrote:

            
I get the impression that you are confusing ``??'' and ``?''.

If you type ``?normal'' you get a ``No documentation found'' message.

If you type ``??normal'' you indeed get a long list of pages, some of
which might be relevant.  (If you want help on ``dnorm'' then the  
relevant
page is stats::Normal.  And then typing ``?Normal'' gets you what you
want.  Which is somewhat on the obscure side of obvious, IMHO.)

If you type ``?dnorm'' then you get exactly what you want immediately.
Exactly?  Well, there's also info on pnorm, qnorm, and rnorm, but I
expect you can live with that.

Note that listing base functions first won't help you at all in this
instance, since dnorm is in ***stats***, not in ***base***.

There is no easy answer to ``How do I find the right function when I
can't remember its name?''.  The ``??'' construct, RSiteSearch(),
some Wiki-s that lurk about the traps, the task views on CRAN, and a
few other things all help, but none of them solves the problem  
completely.
When all else fails, post to this list and resign yourself to the fact
you'll probably get a flame along with the answer to your question!

	cheers,

		Rolf Turner

######################################################################
Attention:\ This e-mail message is privileged and confid...{{dropped:9}}
#
??'normal distribution' seems to do rather well.  If you know that you 
want results from 'stats' you can confine the search to that package.

'normal' is such an overloaded word that searching for it is going to 
be overwhelming.  At least 'Normal' is AFAIR only used in one sense in 
statistics.

``onr could argue that listing the standard and recommended packades 
at the top of the help.search results -- patches to do so would be 
considered.  (Some of us keep other packages in separate libraries, in 
which case searching in R --vanilla does this automaticaly.)

A quck look at a good book on S/R would solve such basic issues as 
quickly as anything.
On Sun, 25 Jan 2009, Rolf Turner wrote:

            

  
    
#
Michael Kubovy wrote:
[...]
It sounds to me like here you want:

args(dnorm)

Patrick Burns
patrick at burns-stat.com
+44 (0)20 8525 0696
http://www.burns-stat.com
(home of "The R Inferno" and "A Guide for the Unwilling S User")
#
On Sun, 25 Jan 2009, Patrick Burns wrote:

            
or, for functions hidden in a namespace, argsAnywhere().

        -thomas

Thomas Lumley			Assoc. Professor, Biostatistics
tlumley at u.washington.edu	University of Washington, Seattle
#
On Jan 25, 2009, at 9:35 , Michael Kubovy wrote:

            
"?" is interpreted by JGR (re-mapped to internal call to help followed  
by help.search if no topics were found) instead of R. So JGR is  
smarter than R used to be, but that has changed in R 2.8.  
Unfortunately R has currently no publicly available API to support  
what the Mac-GUI does, because it uses a nasty trick by modifying R's  
sources to hook inside R. I'm working on fixing this for R 2.9.0-to- 
be, but currently JGR is out of luck and has to rely on its own  
attempts to parse the command line, so the results will vary until then.
I can see what could cause that, but in theory that should affect all  
html-based systems if R really doesn't update the links. I didn't  
actually look but it's possible that JGR just needs to call  
make.packages.html() -- in effect, try calling that function and if  
that solves your problem that's what's it is ...


Cheers,
S