Skip to content
Prev 40220 / 63424 Next

How to document man/*.Rd pages with images?

Hi,

On Wed, May 11, 2011 at 3:42 PM, Sean Robert McGuffee
<sean.mcguffee at gmail.com> wrote:
Think of vignettes as "tutorials" you include in your package to show
how consumers of your package can use it in different ways ..
something like an advertisement of how cool your package really is,
which is a bit harder for a user to appreciate by just browsing a list
of function documentation (which the *.Rd files generate).

As you are suspecting, they are indeed different than the help files
that pop up via the ?myFunction route.
I actually don't believe you can do this.
They are not the same.

A good source to learn more about what you might use vignettes for are
the bioconductor packages. All bioconductor packages are required
(strongly encouraged(?)) to include vignettes. For example, look at
their ShortRead package:

http://www.bioconductor.org/packages/release/bioc/html/ShortRead.html

In the "Documentation" section, you will find two vignettes there,
both of which include pictures embedded in them.

I can see how including pics in the function documentation can also be
helpful. An alternative is to have the pictures that you would include
in these files be generated by the code in the "Examples" section of
your function documentation, so that the user can do:

R> example(yourFunction)

And have R produce the plots "live".
Only if you want to embed images in some type of documentation.

They're more or less ordinary LaTeX files that you can embed R code
into. Very handy to know how to use, actually, even outside of the
"Package Authoring" context, so ... perhaps you can consider it as
good exercise if you decide to take it on :-)

But again, you can always go the other route I proposed, which is to
have your Example code generate these plots on the fly.

In hopes of saving you some time, to go the "Example route," it is
often helpful to include a small example dataset in your package that
your Example code can load and work off of.

Hope that helps,

-steve

Thread (25 messages)

Sean Robert McGuffee How to document man/*.Rd pages with images? May 11 Dan Tenenbaum How to document man/*.Rd pages with images? May 11 Sean Robert McGuffee How to document man/*.Rd pages with images? May 11 Hadley Wickham How to document man/*.Rd pages with images? May 11 Thomas Roth How to document man/*.Rd pages with images? May 11 Steve Lianoglou How to document man/*.Rd pages with images? May 11 Simon Urbanek How to document man/*.Rd pages with images? May 11 Thomas Roth How to document man/*.Rd pages with images? May 11 Paul Gilbert How to document man/*.Rd pages with images? May 11 Simon Urbanek How to document man/*.Rd pages with images? May 11 Thomas Roth How to document man/*.Rd pages with images? May 11 Sean Robert McGuffee How to document man/*.Rd pages with images? May 11 Sean Robert McGuffee How to document man/*.Rd pages with images? May 11 Simon Urbanek How to document man/*.Rd pages with images? May 11 Duncan Murdoch How to document man/*.Rd pages with images? May 11 Duncan Murdoch How to document man/*.Rd pages with images? May 11 Thomas Roth How to document man/*.Rd pages with images? May 11 Hadley Wickham How to document man/*.Rd pages with images? May 11 Paul Gilbert How to document man/*.Rd pages with images? May 11 Sean Robert McGuffee How to document man/*.Rd pages with images? May 11 Simon Urbanek R html help system [Was: How to document man/*.Rd pages with images?] May 12 Sean Robert McGuffee R html help system [Was: How to document man/*.Rd pages with images?] May 13 Simon Urbanek R html help system [Was: How to document man/*.Rd pages with images?] May 13 Sean Robert McGuffee R html help system [Was: How to document man/*.Rd pages with images?] May 16 Hervé Pagès R html help system [Was: How to document man/*.Rd pages with images?] May 16