Skip to content
Prev 2883 / 15075 Next

Weird problem redirecting lattice graph to a file

Hello,

I am having this weird issue where I cannot send a lattice graph to a device
like pdf() or png(), but this only happens when the statement is inside a
function. For example, this works:
But now, put the last three statements in a function (F(a)) and the pdf is
not produced. I tried replacing pdf with
trellis.device(device="pdf",file="test.pdf") and it still does not work.

Funny thing is that plot() or image() will work inside a function as
expected when re-directing to other devices, but not any of the lattice
functions.

Any ideas?

Thanks,

Jorge