Hello, I would like to save different plots and some text (like summaries, AIC, ...) on the same file. I've read the e-mails entitled "Output results to a single postscript document" written some days ago and I've tried to use the function odfInsertPlot() in the package "odfWeave" but it doesn't work on my computer (I've seen that odfWeave package depends on XML package, which is not available for windows...) Does somebody know if there is another function or package that could help? I would need at least to put all the plots on the same file ... of course I could copy and paste them by hand but there are tens of graphs... :-( Thanks!! Laura
plots and text to the same output file
4 messages · lauramorgana at bluewin.ch, Greg Snow, Michael Bibo +1 more
odfWeave works just fine for me on windows and the XML package shows up in my list of packages. You may be overthinking the problem, for most of my odfWeave projects I don't need odfInsertPlot, just use fig=TRUE in the code chunk and only include the code for that 1 plot in that code chunk (a separate chunk for each plot) and the inclusion of the plot is taken care of for you (you can do fancier things with odfInsertPlot, but probably don't need to most of the time). Another alternative for creating postscript (which can be converted to pdf if that is preferred), but which is much less sophisticated than sweave/odfWeave is to look at the etxtStart function in the TeachingDemos package (this requires postprocessing with enscript). This approach is more for getting a transcript of an interactive session, for planned analyses use sweave/odfWeave instead. Hope this helps,
Gregory (Greg) L. Snow Ph.D. Statistical Data Center Intermountain Healthcare greg.snow at imail.org 801.408.8111 > -----Original Message----- > From: r-help-bounces at r-project.org [mailto:r-help-bounces at r- > project.org] On Behalf Of lauramorgana at bluewin.ch > Sent: Wednesday, February 11, 2009 11:27 AM > To: r-help at r-project.org > Subject: [R] plots and text to the same output file > > Hello, > I would like to save different plots and some text (like summaries, > AIC, ...) on the same file. > I've read the e-mails entitled "Output results to a single postscript > document" written some days ago and I've tried > to use the function odfInsertPlot() in the package "odfWeave" but it > doesn't work on my computer (I've seen that > odfWeave package depends on XML package, which is not available for > windows...) > Does somebody know if there is another function or package that could > help? I would need at least to put all the > plots on the same file > ... of course I could copy and paste them by hand but there are tens of > graphs... :-( > > Thanks!! > Laura > > ______________________________________________ > R-help at r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting- > guide.html > and provide commented, minimal, self-contained, reproducible code.
Greg Snow <Greg.Snow <at> imail.org> writes:
odfWeave works just fine for me on windows and the XML package shows up in
my list of packages. You may be
overthinking the problem, for most of my odfWeave projects I don't need
odfInsertPlot, just use fig=TRUE
in the code chunk and only include the code for that 1 plot in that code
chunk (a separate chunk for each plot)
and the inclusion of the plot is taken care of for you (you can do fancier
things with odfInsertPlot, but
probably don't need to most of the time). Another alternative for creating postscript (which can be converted to pdf
if that is preferred), but
which is much less sophisticated than sweave/odfWeave is to look at the
etxtStart function in the
TeachingDemos package (this requires postprocessing with enscript). This
approach is more for getting
a transcript of an interactive session, for planned analyses use
sweave/odfWeave instead.
Hope this helps,
See also package hwriter, for creating HTML output files which can be further edited, even with MSWord if you work with others in an MSOffice environment. Michal Bibo
lauramorgana at bluewin.ch wrote:
Hello, I would like to save different plots and some text (like summaries, AIC, ...) on the same file. I've read the e-mails entitled "Output results to a single postscript document" written some days ago and I've tried to use the function odfInsertPlot() in the package "odfWeave" but it doesn't work on my computer (I've seen that odfWeave package depends on XML package, which is not available for windows...) Does somebody know if there is another function or package that could help? I would need at least to put all the plots on the same file ... of course I could copy and paste them by hand but there are tens of graphs...
Hi Laura, Both the R2HTML package and the htmlize and R2html functions in the prettyR package enable saving the output of a session in an HTML file (with associated image files). The latter two functions are particularly easy if you already have a running script and want to get the output in an easily viewable format. The advantage of HTML is that it can be displayed by "any damn browser". Jim