[R] Changing background in splom et al.
Deepayan Sarkar
deepayan at stat.wisc.edu
Wed Mar 3 16:15:28 CET 2004
On Wednesday 03 March 2004 05:09, v.demartino2 at virgilio.it wrote:
> Context: Windows XP, R 1.8.1
>
> I'm studying Venables-Ripley "MASS" book and having a go at the many
> examples in library MASS. The code I'm checking (from script ch04.R) now
> is
>
> ......
> data(swiss)
> splom(~ swiss, aspect = "fill",
> panel = function(x, y, ...) {
> panel.xyplot(x, y, ...); panel.loess(x, y, ...)
> }
> )
>
> which produces an agreable plot with a gray background and cyan points,
> but.....
> Copying the plot as a metafile into Word and having a laser printer I'd
> better stick to a b/w plot.
>
> How can I turn the background to white and the cyan points to black?
You probably want to do
trellis.device(color = FALSE)
or
trellis.device(device = "win.metafile", ## or whatever the device name is
color = FALSE)
before calling splom().
Deepayan
More information about the R-help
mailing list