Hi, I output multiple "grid-package-based" plots to the postscript device. Because the graphics are complicated and consists of a lot of datapoints (~200'000) the files become really big. To avoid this big files and to shorten the creation, I currently print the plots to the png device and manually combine them into one multipaged pdf document. My question is, it is possible to do this in R directly? Probably I would have to create a png plot first, then reimport it into R and "put" it on the ps device. Is this a realistic way (in principle) ? If there is no package to read png files (I didn't find anything), I probably could solve this. But I still don't know if it would be possible to "put" this memory representation to a ps device. Thanks for your time. -- Regards, Hans-Peter [[alternative HTML version deleted]]
On Fri, 1 Sep 2006, Hans-Peter wrote:> Hi, > > I output multiple "grid-package-based" plots to the postscript device. > Because the graphics are complicated and consists of a lot of datapoints > (~200'000) the files become really big. To avoid this big files and to > shorten the creation, I currently print the plots to the png device and > manually combine them into one multipaged pdf document. > > My question is, it is possible to do this in R directly? > Probably I would have to create a png plot first, then reimport it into R > and "put" it on the ps device. Is this a realistic way (in principle) ? > > If there is no package to read png files (I didn't find anything), I > probably could solve this.There are various ways to do so: one is to convert to a format pixmap knows, another to convert to TIFF and use rtiff.> But I still don't know if it would be possible to > "put" this memory representation to a ps device.Only crudely. There is nothing in the R graphics model related to bitmaps. What you could do is draw each pixel as a rectangle (as image() does), but then your file size will be even bigger and the chances of it being rendered accurately are not high. -- Brian D. Ripley, ripley at stats.ox.ac.uk Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ University of Oxford, Tel: +44 1865 272861 (self) 1 South Parks Road, +44 1865 272866 (PA) Oxford OX1 3TG, UK Fax: +44 1865 272595
Hi Hans-Peter wrote:> Hi, > > I output multiple "grid-package-based" plots to the postscript device. > Because the graphics are complicated and consists of a lot of datapoints > (~200'000) the files become really big. To avoid this big files and to > shorten the creation, I currently print the plots to the png device and > manually combine them into one multipaged pdf document.If you want to automate combining png files into a single pdf, you could take a look at ImageMagick. Paul> My question is, it is possible to do this in R directly? > Probably I would have to create a png plot first, then reimport it into R > and "put" it on the ps device. Is this a realistic way (in principle) ? > > If there is no package to read png files (I didn't find anything), I > probably could solve this. But I still don't know if it would be possible to > "put" this memory representation to a ps device. > > Thanks for your time. >-- Dr Paul Murrell Department of Statistics The University of Auckland Private Bag 92019 Auckland New Zealand 64 9 3737599 x85392 paul at stat.auckland.ac.nz http://www.stat.auckland.ac.nz/~paul/
Maybe Matching Threads
- display SVG, PNG, GIF, JPEG, TIFF, PPM in new plot frame
- Making TIFF images with rtiff
- [Spice-devel] [PATCH] Revert "drm/qxl: drop prime import/export callbacks"
- [Spice-devel] [PATCH] Revert "drm/qxl: drop prime import/export callbacks"
- png and pdf : point size, font size, etc.