Re: [R] R versions and PostScript files

2011-08-30 Thread Prof Brian Ripley
On Fri, 22 Jul 2011, James Cloos wrote: Please do note the posting guide: the context you omitted (when explicitly asked not to) is in the thread starting: https://stat.ethz.ch/pipermail/r-help/2011-July/284352.html I suspect that a few s/def/bind def/ on that prologue might improve things a

Re: [R] R versions and PostScript files

2011-07-24 Thread Uwe Ligges
On 22.07.2011 19:46, pilchat wrote: Thank you David, the useRaster=T does the trick! But, unfortunately, it doesn't work for persp. Is there any way to avoid the sRGB colors at the beginning of the R session? I tried to edit my Rprofile: .First<- function() { a<-system("ls /dati/softwa

Re: [R] R versions and PostScript files

2011-07-22 Thread James Cloos
I suspect that a few s/def/bind def/ on that prologue might improve things a bit. The ps R creates freely switches between the sRGB ABC space and setgray. That is a good thing; it helps ensure that black will be just black when sent to a CMYK device. Without that you can get CMY black from some

Re: [R] R versions and PostScript files

2011-07-22 Thread pilchat
Thank you David, the useRaster=T does the trick! But, unfortunately, it doesn't work for persp. Is there any way to avoid the sRGB colors at the beginning of the R session? I tried to edit my Rprofile: .First <- function() { a<-system("ls /dati/software/R_lib/*.r",intern=T) for (i in a)

Re: [R] R versions and PostScript files

2011-07-22 Thread James Cloos
I suspect that a few s/def/bind def/ on that prologue might improve things a bit. The ps R creates freely switches between the sRGB ABC space and setgray. That is a good thing; it helps ensure that black will be just black when sent to a CMYK device. Without that you can get CMY black from some

Re: [R] R versions and PostScript files

2011-07-22 Thread David Smith
Another option in this specific case is to use the new useRaster=TRUE option, which makes the image function generate much more compact and faster-rendering image plots. This code: setEPS() postscript (file="volc.eps",width=5,height=4) image(volcano,useRaster=TRUE) dev.off() in R 2.13 generates a

Re: [R] R versions and PostScript files

2011-07-22 Thread pilchat
That's great! Thank you all!! Final question: how can I edit permanently the .ps.prolog? Is the .First() function an option? Please, tell me every detail as I am a total dumb! Many thanks Gaetano On Fri, Jul 22, 2011 at 11:27 AM, Ted Harding wrote: > On 22-Jul-11 09:20:23, peter dalgaard wrot

Re: [R] R versions and PostScript files

2011-07-22 Thread pilchat
I tried with the option sRGB=F in the postscript() command, but I got the error message "unused argument(s) (sRGB = F)" I think that Peter's solution is the best one, as it consists, as far as I understand, in changing the default content of .ps.postscript. The problem is that I don't know how to

Re: [R] R versions and PostScript files

2011-07-22 Thread Rainer M Krug
On Fri, Jul 22, 2011 at 9:55 AM, pilchat wrote: > I tried with the option sRGB=F in the postscript() command, but I got the > error message "unused argument(s) (sRGB = F)" > True - because that option is not there, but to include one wopuld be an option. > > I think that Peter's solution is th

Re: [R] R versions and PostScript files

2011-07-22 Thread peter dalgaard
On Jul 22, 2011, at 11:08 , (Ted Harding) wrote: > On 22-Jul-11 08:02:40, peter dalgaard wrote: >> [much snip] >> >> The .ps.prolog is not in C code but in an R character vector. > > While '?postscript' says (uder "Details:"): > > > Most of the PostScript prologue used is taken from the > R

Re: [R] R versions and PostScript files

2011-07-22 Thread Ted Harding
On 22-Jul-11 09:20:23, peter dalgaard wrote: > > On Jul 22, 2011, at 11:08 , (Ted Harding) wrote: > >> On 22-Jul-11 08:02:40, peter dalgaard wrote: >>> [much snip] >>> >>> The .ps.prolog is not in C code but in an R character vector. >> >> While '?postscript' says (uder "Details:"): >> >> >>

Re: [R] R versions and PostScript files

2011-07-22 Thread Rainer M Krug
On Fri, Jul 22, 2011 at 10:02 AM, peter dalgaard wrote: > > On Jul 22, 2011, at 09:04 , Rainer M Krug wrote: > > > On Fri, Jul 22, 2011 at 12:44 AM, Duncan Murdoch > > wrote: > > > >> On 11-07-21 5:17 PM, pilchat wrote: > >> > >>> thank you guys for your reply. > >>> > >>> i was sure that it was

Re: [R] R versions and PostScript files

2011-07-22 Thread Ted Harding
On 22-Jul-11 08:02:40, peter dalgaard wrote: > [much snip] > > The .ps.prolog is not in C code but in an R character vector. While '?postscript' says (uder "Details:"): Most of the PostScript prologue used is taken from the R character vector '.ps.prolog'. This is marked in the output, a

Re: [R] R versions and PostScript files

2011-07-22 Thread peter dalgaard
On Jul 22, 2011, at 09:04 , Rainer M Krug wrote: > On Fri, Jul 22, 2011 at 12:44 AM, Duncan Murdoch > wrote: > >> On 11-07-21 5:17 PM, pilchat wrote: >> >>> thank you guys for your reply. >>> >>> i was sure that it was related to changes in the generation of ps >>> files with the latest R rele

Re: [R] R versions and PostScript files

2011-07-22 Thread Rainer M Krug
On Fri, Jul 22, 2011 at 12:44 AM, Duncan Murdoch wrote: > On 11-07-21 5:17 PM, pilchat wrote: > >> thank you guys for your reply. >> >> i was sure that it was related to changes in the generation of ps >> files with the latest R release. >> >> now the question is: how can i restore the old behavio

Re: [R] R versions and PostScript files

2011-07-21 Thread Duncan Murdoch
On 11-07-21 5:17 PM, pilchat wrote: thank you guys for your reply. i was sure that it was related to changes in the generation of ps files with the latest R release. now the question is: how can i restore the old behavior in R2.13? Peter told you. Duncan Murdoch thanks gaetano On 7/21/1

Re: [R] R versions and PostScript files

2011-07-21 Thread pilchat
thank you guys for your reply. i was sure that it was related to changes in the generation of ps files with the latest R release. now the question is: how can i restore the old behavior in R2.13? thanks gaetano On 7/21/11, Ted Harding wrote: > Yes, Peter, your suggestion does the trick (at an

Re: [R] R versions and PostScript files

2011-07-21 Thread Ted Harding
Yes, Peter, your suggestion does the trick (at any rate with Gaetano's files). I edited his volc2.13.eps (the slow one) as follows (the original commented out with "%%##") making just the following change: %%## /setrgb { srgb setcolor } def /setrgb { setrgbcolor } def %%## End of editing (at lin

Re: [R] R versions and PostScript files

2011-07-21 Thread peter dalgaard
This is due to the introduction of sRGB. Since this actually does something (Google for sRGB and you will be approximately as wise as me...), I don't think it is likely to be taken out. You can, however, always edit .ps.prolog. (I would expect that the line /setrgb { setrgbcolor } def instead

Re: [R] R versions and PostScript files

2011-07-21 Thread Ted Harding
On 21-Jul-11 13:24:32, Duncan Murdoch wrote: > On 11-07-21 3:23 AM, pilchat wrote: >> Dear R users, >> >> I have a desktop computer and a laptop, both of them >> with Ubuntu Lucid. The former has R2.10 installed from >> Ubuntu repositories (this is the most recent version >> in the repositories), w

Re: [R] R versions and PostScript files

2011-07-21 Thread Duncan Murdoch
On 11-07-21 3:23 AM, pilchat wrote: Dear R users, I have a desktop computer and a laptop, both of them with Ubuntu Lucid. The former has R2.10 installed from Ubuntu repositories (this is the most recent version in the repositories), while the latter has R2.13 from the CRAN repositories. I notic

Re: [R] R versions and PostScript files

2011-07-21 Thread pilchat
Hi Ted, the two ps files are generated using exactly the same script. For example: -- setEPS() postscript (file="volc.eps",width=5,height=4) image(volcano) dev.off() -- With R2.10 I get a file with size 182K, while R2.13 gives a file of 186K. I am

Re: [R] R versions and PostScript files

2011-07-21 Thread Ted Harding
On 21-Jul-11 07:23:54, pilchat wrote: > Dear R users, > > I have a desktop computer and a laptop, both of them with > Ubuntu Lucid. The former has R2.10 installed from Ubuntu > repositories (this is the most recent version in the > repositories), while the latter has R2.13 from the CRAN > reposito