On Tue, Feb 25, 2014 at 01:45:40PM -0500, epi wrote: > Hi, > > You can try to use cairo instead of png. > IT doesn?t require X. > try putting this line in a Rprofile file : > > > options(bitmapType="cairo") > ..
Thank you for the suggestion.
Early in the first function my script invokes, I have:
options(width = 120)
so I inserted the line:
options(bitmapType="cairo")
just after that. Re-running the script (from an environment without the
DISPLAY environment variable set) yields:
| Error in .External2(C_X11, paste("png::", filename, sep = ""), g$width, :
| unable to start device PNG
| Calls: gen_build_histogram -> png
| In addition: Warning message:
| In png(filename = fn, height = height, width = width, units = "in", :
| unable to open connection to X11 display ''
| Execution halted
(as before).
On Tue, Feb 25, 2014 at 01:51:58PM -0500, Ista Zahn wrote:
> Hi David,
>
> Did you see https://stat.ethz.ch/pipermail/r-help/2010-March/231778.html
> ? What does capabilities() tell you?
I had not seen that particular message, no; thank you for pointing it out.
When I try that, I see:
dwolf-fbsd(9.2-S)[3] echo $DISPLAY
DISPLAY: Undefined variable.
dwolf-fbsd(9.2-S)[4] R
R version 3.0.2 Patched (2013-11-12 r64207) -- "Frisbee Sailing"
Copyright (C) 2013 The R Foundation for Statistical Computing
Platform: amd64-portbld-freebsd9.2 (64-bit)
R is free software and comes with ABSOLUTELY NO WARRANTY.
...
> capabilities()
jpeg png tiff tcltk X11 aqua http/ftp sockets
FALSE FALSE FALSE TRUE FALSE FALSE TRUE TRUE
libxml fifo cledit iconv NLS profmem cairo
TRUE TRUE TRUE TRUE TRUE TRUE FALSE
> options(bitmapType="cairo")
> capabilities()
jpeg png tiff tcltk X11 aqua http/ftp sockets
FALSE FALSE FALSE TRUE FALSE FALSE TRUE TRUE
libxml fifo cledit iconv NLS profmem cairo
TRUE TRUE TRUE TRUE TRUE TRUE FALSE
>
Compare the above with:
dwolf-fbsd(9.2-S)[15] echo $DISPLAY
localhost:11.0
dwolf-fbsd(9.2-S)[16] R
R version 3.0.2 Patched (2013-11-12 r64207) -- "Frisbee Sailing"
Copyright (C) 2013 The R Foundation for Statistical Computing
Platform: amd64-portbld-freebsd9.2 (64-bit)
R is free software and comes with ABSOLUTELY NO WARRANTY.
...
> capabilities()
jpeg png tiff tcltk X11 aqua http/ftp sockets
TRUE TRUE TRUE TRUE TRUE FALSE TRUE TRUE
libxml fifo cledit iconv NLS profmem cairo
TRUE TRUE TRUE TRUE TRUE TRUE FALSE
> options(bitmapType="cairo")
> capabilities()
jpeg png tiff tcltk X11 aqua http/ftp sockets
TRUE TRUE TRUE TRUE TRUE FALSE TRUE TRUE
libxml fifo cledit iconv NLS profmem cairo
TRUE TRUE TRUE TRUE TRUE TRUE FALSE
>
> ...
Peace,
david
--
David H. Wolfskill [email protected]
Taliban: Evil cowards with guns afraid of truth from a 14-year old girl.
See http://www.catwhisker.org/~david/publickey.gpg for my public key.
pgpB_Cs47XA_j.pgp
Description: PGP signature
______________________________________________ [email protected] 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.

