Issue
I am use R 2.14.0 on Debian Squeeze. I am running R in the terminal. Currently when I type
?myfunction
, the help page is displayed in the terminal. I would like for the help page to be displayed in my web browser instead, just like on Windows (or Fedora). How do I do this?
I have tried typing help.start()
but it did not do anything.
UPDATE: I got it working once, then it stopped working. I added the following lines to $R_HOME/etc/.Rprofile
options("help_type"="html")
options("browser"="chromium-browser")
It worked once. Then stopped.
help.start()
now launches the browser. However, ?someFunction
only launched the browser once and has now reverted to the in-terminal help.
Thanks.
Solution
For a single query, use the help_type
argument to help()
, like this:
help(myfunction, help_type="html")
To set the help type for the current R session, set,
options(help_type="html")
Finally, to change the default help type for all R sessions, add the following line to your .Rprofile.site
file, located in $R_HOME/etc/.Rprofile.site
(or to one of the other .Rprofile
files described in ?Startup
):
options("help_type"="html")
Answered By - Josh O'Brien