Deal all, new as I am to developing packages for R-Project, I apologize on beforehand for questions that are too obvious. I am trying to 'add' a PDF document containing some detailed information to a package. The way I understand the Rexts.pdf document, I should add my .PDF document to the /inst/doc/ folder, and links to the files should be build automatically. However, after building it on MacOSX (10.4) using 'R CMD build' and checking it using 'R CMD check', no links seems to be present. All checks are OK, but no vignette or whatever appears in the help-files of the package. Clearly, I'm missing something. I would really appreciate some pointers on how to integrate an 'additional' pdf file to my package. Thanks in advance, Rense Nieuwenhuis
Adding .PDF files to a package
6 messages · Rense Nieuwenhuis, Wolfgang Huber, Mathieu Ribatet +1 more
Rense Nieuwenhuis wrote:
Deal all, new as I am to developing packages for R-Project, I apologize on beforehand for questions that are too obvious. I am trying to 'add' a PDF document containing some detailed information to a package. The way I understand the Rexts.pdf document, I should add my .PDF document to the /inst/doc/ folder, and links to the files should be build automatically. However, after building it on MacOSX (10.4) using 'R CMD build' and checking it using 'R CMD check', no links seems to be present. All checks are OK, but no vignette or whatever appears in the help-files of the package. Clearly, I'm missing something. I would really appreciate some pointers on how to integrate an 'additional' pdf file to my package. Thanks in advance, Rense Nieuwenhuis
Hi Rense
This is probably not the prettiest solution, and I'd be curious about
better ones from people on this list, but here's one possibility:
1.) Put your PDF file foo.pdf into the inst/pdfs folder of your package.
2.) Create a file foo.Rnw with following content in inst/doc
------------------------------------------
%\VignetteIndexEntry{The Foo Bar}
\documentclass{article}
\begin{document}
\end{document}
------------------------------------------
3.) Create a Makefile in inst/doc, with contents like:
---------------------------------------
all: foo bar
bar: bar.tex
pdflatex bar
pdflatex bar
foo: foo.tex
cp -p ../pdfs/foo.pdf .
---------------------------------------
Bw
Wolfgang
----------------------------------------------------
Wolfgang Huber, EMBL-EBI, http://www.ebi.ac.uk/huber
Wolfgang Huber wrote:
Rense Nieuwenhuis wrote:
Deal all, new as I am to developing packages for R-Project, I apologize on beforehand for questions that are too obvious. I am trying to 'add' a PDF document containing some detailed information to a package. The way I understand the Rexts.pdf document, I should add my .PDF document to the /inst/doc/ folder, and links to the files should be build automatically. However, after building it on MacOSX (10.4) using 'R CMD build' and checking it using 'R CMD check', no links seems to be present. All checks are OK, but no vignette or whatever appears in the help-files of the package. Clearly, I'm missing something. I would really appreciate some pointers on how to integrate an 'additional' pdf file to my package. Thanks in advance, Rense Nieuwenhuis
Hi Rense
This is probably not the prettiest solution, and I'd be curious about
better ones from people on this list, but here's one possibility:
1.) Put your PDF file foo.pdf into the inst/pdfs folder of your package.
2.) Create a file foo.Rnw with following content in inst/doc
------------------------------------------
%\VignetteIndexEntry{The Foo Bar}
\documentclass{article}
\begin{document}
\end{document}
------------------------------------------
3.) Create a Makefile in inst/doc, with contents like:
---------------------------------------
all: foo bar
bar: bar.tex
pdflatex bar
pdflatex bar
foo: foo.tex
cp -p ../pdfs/foo.pdf .
---------------------------------------
I'd like to add that doing so will frustrate those users that have come to expect that a vignette is reproducible and can be reproduced by the user through running Sweave on the source file. It will depend on your particular context how to best provide for that (e.g. by telling people how to build your PDF using other tools, or by explicitly advertising that this is not a reproducible document.) browseVignettes() and vignette() provide nice standardized ways of finding vignettes, and they are easily found in the index page of the package manual pages; perhaps a similarly standardized way of accessing such additional PDFs etc. without the above subversion of vignette infrastructure would be the best solution. Best wishes Wolfgang
Dear Rense, The way you included your pdf file in your package is appropriate. Normally, when invocking "help.start()" and going to your package link, you should have two links overview and directory where your pdf file should be located. Best, Mathieu Rense Nieuwenhuis a ?crit :
Deal all, new as I am to developing packages for R-Project, I apologize on beforehand for questions that are too obvious. I am trying to 'add' a PDF document containing some detailed information to a package. The way I understand the Rexts.pdf document, I should add my .PDF document to the /inst/doc/ folder, and links to the files should be build automatically. However, after building it on MacOSX (10.4) using 'R CMD build' and checking it using 'R CMD check', no links seems to be present. All checks are OK, but no vignette or whatever appears in the help-files of the package. Clearly, I'm missing something. I would really appreciate some pointers on how to integrate an 'additional' pdf file to my package. Thanks in advance, Rense Nieuwenhuis
______________________________________________ R-devel at r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel
Institute of Mathematics Ecole Polytechnique F?d?rale de Lausanne STAT-IMA-FSB-EPFL, Station 8 CH-1015 Lausanne Switzerland http://stat.epfl.ch/ Tel: + 41 (0)21 693 7907
An embedded and charset-unspecified text was scrubbed... Name: not available URL: <https://stat.ethz.ch/pipermail/r-devel/attachments/20080806/9c36bb47/attachment.pl>
This seems a bit too simplistic but, does it make any difference if your file is .pdf rather than .PDF? Paul
Rense Nieuwenhuis wrote:
Dear Mathieu, thank you for your assurance that my manual-reading-skills are on par! ;-) The thing is, though, that I can't get it to work. In the index of the help pages, it reads: ''Read overview or browse directory". The 'browse directory' option does not work. When clicked on the 'Read overview' option, the following text appears: "Vignettes of package Read.isi Sorry, the package contains no vignette meta-information or index. Please browse the directory." So, clearly, some links are missing. Should I manually create an index file? If so, how do I specify the link to the .PDF file? I hope someone can help[. Thank in advance, Rense Nieuwenhuis - - -- --- ----- -------- Rense Nieuwenhuis +31 6 481 05 683 www.rensenieuwenhuis.nl On Aug 6, 2008, at 17:40 , Mathieu Ribatet wrote:
Dear Rense, The way you included your pdf file in your package is appropriate. Normally, when invocking "help.start()" and going to your package link, you should have two links overview and directory where your pdf file should be located. Best, Mathieu Rense Nieuwenhuis a ?crit :
Deal all, new as I am to developing packages for R-Project, I apologize on beforehand for questions that are too obvious. I am trying to 'add' a PDF document containing some detailed information to a package. The way I understand the Rexts.pdf document, I should add my .PDF document to the /inst/doc/ folder, and links to the files should be build automatically. However, after building it on MacOSX (10.4) using 'R CMD build' and checking it using 'R CMD check', no links seems to be present. All checks are OK, but no vignette or whatever appears in the help-files of the package. Clearly, I'm missing something. I would really appreciate some pointers on how to integrate an 'additional' pdf file to my package. Thanks in advance, Rense Nieuwenhuis
______________________________________________ R-devel at r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel
-- Institute of Mathematics Ecole Polytechnique F?d?rale de Lausanne STAT-IMA-FSB-EPFL, Station 8 CH-1015 Lausanne Switzerland http://stat.epfl.ch/ Tel: + 41 (0)21 693 7907
[[alternative HTML version deleted]] ------------------------------------------------------------------------
______________________________________________ R-devel at r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel
====================================================================================
La version fran?aise suit le texte anglais.
------------------------------------------------------------------------------------
This email may contain privileged and/or confidential in...{{dropped:26}}