Hi, Duncan:

On 10/18/2015 8:18 PM, Duncan Murdoch wrote:
On 18/10/2015 5:51 PM, Spencer Graves wrote:
Hello:


        What's the preferred way to link to package documentation from a
vignette using markdown?


        My current draft includes
"[cumsum](https://stat.ethz.ch/R-manual/R-devel/library/base/html/cumsum.html)"
to link to the help page for cusum{base} and
"[KFAS](https://rweb.crmda.ku.edu/cran/web/packages/KFAS/KFAS.pdf)" to
link to the pdf documentation for the KFAS package.  This works, but it
feels like an ugly hack, and I wonder if there might be some more
elegant way of doing this (documented in a fine manual I have yet to find)?
You can include links that work only when R is displaying the help using
relative URLs like

../../base/help/cumsum

or

../../base/html/cumsum.html

(The former is like doing ?cumsum, i.e. it uses the alias; the latter
goes directly to a page by its name.)

The advantage of this kind of link is it doesn't need an Internet
connection, it works with the R help system; the disadvantage is that it
only works when the help system is running, so those links won't work in
the copy of your vignette on CRAN, for example.


Thanks. I think I saw links like these reading html trying to find what I needed for [KFAS]; this helps me understand what I read. I think I'd prefer having links that work in a pdf that I could pass to someone who may not have R installed.


What's the easiest way to find links like the absolute web address I gave for [KFAS]? It took me a couple of hours, because I couldn't find how to get more than "https://rweb.crmda.ku.edu/cran/"; from any of my current web browsers (Safari, Chrome, and SeaMonkey on OS X 10.11, Internet Explorer, Chrome, FireFox and SeaMonkey under Windows 7).


      Thanks again,
      Spencer

Duncan Murdoch

______________________________________________
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel

Reply via email to