[R] Sweave: pdf-graphics got three times lager with R 2.13.1

Prof Brian Ripley ripley at stats.ox.ac.uk
Thu Aug 11 18:50:46 CEST 2011


1) Read about the changes to the colourspace in 2.13.0.

2) Try R-devel: it has compression for PDF files (or use a compressor 
on your final pdf file, e.g. tools::compactPDF).

On Thu, 11 Aug 2011, Uwe Ligges wrote:

>
>
> On 04.08.2011 13:44, eriksengewald wrote:
>> Dear R-Users,
>> 
>> I am using R for years now but recently I encounter a problem with the
>> pdf-size of graphics generated with sweave. However, I am new in this 
>> forum.
>> Hence, please don't hesitate if I am wrong here.
>> 
>> I use a script which runs perfectly in R 2.11.1 and the pdf-size of the
>> graphs is about 3 KB. Running the same script with R 2.13.1 the file size
>> increases to 12 KB. I am using about 300 pdf-pictures in my tex-file,
>> generated by sweave. So this change in file size is dramatic for the 
>> finally
>> pdf-file.
>> 
>> Has somebody an explanation for this phenomenon?
>
>
> Sometimes improvements to the device functions may lead to such a phenomenon. 
> In this case maybe since the plots are actually really small, some overhead 
> matters.
>
> A minimal reproducible example would help that someone looks into the 
> details, but I doubt this is too important here. I also doubt this is Sweave 
> related. Have you tried a minimal example with the pdf() device directly? 
> Have you read the NEWs about changes since R-2.11.1?
>
> Best,
> Uwe Ligges
>
>
>
>
>> Thanks a lot for your help.
>> 
>> Erik
>> 
>> Here some more facts:
>> - I am running a windows system (same problem with linux system)
>> - This is an example of my code chunk:
>> <<fig=TRUE,echo=false,width=4,height=0.6>>=
>> PlotFunctionRef2(daten,daten_ref1,daten_ref2,g=1) //plotting function
>> @
>> 
>> 
>> --
>> View this message in context: 
>> http://r.789695.n4.nabble.com/Sweave-pdf-graphics-got-three-times-lager-with-R-2-13-1-tp3718378p3718378.html
>> Sent from the R help mailing list archive at Nabble.com.
>> 
>> ______________________________________________
>> 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.
>
> ______________________________________________
> 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.
>

-- 
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



More information about the R-help mailing list