Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

I am writing an R package and would like to make a pdf reference manual of all functions in the package. I understood from here that R CMD check automatically creates a reference manual.

Here I read that a manual entry is created "of the functions you listed in the export section of NAMESPACE".

My NAMESPACE file looks as follows:

# Export all names
exportPattern(".")

# Import all packages listed as Imports or Depends
import(
  LIM
)

so I thought everything will be exported. During R CMD check on the package directory, at the very end it says:

 * checking PDF version of manual ... OK

However, I do not find a reference manual in my package directory (I would assume it would be in inst/doc). What am I missing here?

question from:https://stackoverflow.com/questions/16986422/r-create-reference-manual-with-r-cmd-check

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
659 views
Welcome To Ask or Share your Answers For Others

1 Answer

Another way is to create the reference manual directly using:

R CMD Rd2pdf mypackage

where mypackage is the folder containing your R package code folder structure including the man folder with your .Rd files.

For some reason I never get the reference manual during build or check in RStudio, maybe because I've missed a setting somewhere. But running the command like this works fine as well.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...