Reputation: 21
I'm new to Roxygen and using Roxygen to document my functions and scripts (I'm not building a package, but using the package structure in order to be able to use Roxygen). I use Rd2HTML
function to translate .Rd to .html. I'm trying to make a hyperlink in one .Rd file to another .Rd file, and maintain that link in the .html file.
Suppose I have two scripts and .Rd files: code1
and code2
. When I add \code{\link{code1}}
to the roxygen comments of code2
, run roxygenize("<location of package>")
and use Rd2HTML
to built a html file, the result is that the html-file shows code1
instead of code1 at the location of \code{\link{code1}}
. In other words: no hyperlink is shown in the html file of code1, instead code1
formatted as code is returned. Adding the package name does not resolve the issue.
Can anyone explain this behavior (and solve my issue :))?
Details: NAMESPACE file:
# Generated by roxygen2 (4.1.1): do not edit by hand
export(code1)
export(code2)
DESCRIPTION file:
Package: Scripts
Type: Package
Title: What the package does (short line)
Version: 0.0.1
Date: 2012-11-12
Author: Who wrote it
Maintainer: Who to complain to <[email protected]>
Description: More about what it does (maybe more than one line)
License: GPL
Upvotes: 2
Views: 1206
Reputation: 21
I solved the issue myself. I hadn't installed the package and therefore couldn't locate any .html links.
By the way, http://yihui.name/en/2012/10/build-static-html-help/ helped me to easily build .html pages for help pages.
Upvotes: 0