[Rd] library path in Rd link

Adrian Dusa dusa.adrian at gmail.com
Thu Nov 15 01:00:49 CET 2007


On Thursday 15 November 2007, Duncan Murdoch wrote:
> [...]
> >
> > I understand, thank you. I learned from Prof. Ripley's answer that
> > Windows has link.html.help() function to resolve the html help files from
> > all installed packages.
>
> I didn't know about that; I mainly use the CHMHELP files.  They don't
> support this, being precompiled when the binary package is built.
> Another reason to switch.
>
> The link is probably "../../stats/html/anova.html", and is just being
> displayed by your browser that way.  This is correct:  R installs soft
> links to all packages in one place.  The HTML code doesn't get fixed up
> the way it needs to be on Windows.

It is true, the link was "../../" (my misunderstanding)


> Are you browsing the files from outside of R?  As far as I know (and I
> rarely use Unix so this may be out of date info) the links are set up in
> a temporary directoy when you call .libPaths(), and are removed at the
> end of your session.  I don't know if calling library(foo,
> lib.loc="mine") is enough to link the foo help into the system.

I use:
options(htmlhelp=TRUE)
options(browser="firefox")

I just tried
library(myPackage, lib.loc="myRlibrary")

but I still get

Warning message:
In .show_help_on_topic_as_HTML(file, topic) :
  Using non-linked HTML file: style sheet and hyperlinks may be incorrect

so it seems foo help is not linked into the system.
But there are (at least on Linux) two more than acceptable solutions:

- soft link the folders from /usr/lib/R/library/ to myRlibrary/
(your suggestion, I like it very much and it makes me a happy Linux user)

- use help.start() which links all packages help in a tmp directory
(Prof.Ripley's solution)

Best regards,
Adrian

-- 
Adrian Dusa
Romanian Social Data Archive
1, Schitu Magureanu Bd
050025 Bucharest sector 5
Romania
Tel./Fax: +40 21 3126618 \
          +40 21 3120210 / int.101



More information about the R-devel mailing list