On Sun, 4 Oct 2009 16:14:58 -0400,
Gabor Grothendieck <ggrothendi...@gmail.com> wrote:

> On Sun, Oct 4, 2009 at 3:45 PM, Deepayan Sarkar
> <deepayan.sar...@gmail.com> wrote:

> Yes, unfortunately the trellis object cannot distinguish between the
>> "legend" and the "key" any more.

> If you are willing to muck around at the grid level you can do it.
> First list out the grid objects using grid.ls(). Now looking for 3
> grid text objects in proximity we see 3 such objects as descendants of
> GRID.frame.215 and we examine the first one which, GRID.text.218,
> which indeed contains setosa in its label.  Finally we zap the labels
> of those three grid text objects.

[...]

Thanks everyone.  Besides Gabor's grid approach, another option, short
of redoing the plot entirely, would be to simply target the list element
to remove:

fig$legend[[2]] <- NULL

I don't know if the index (2) would be constant for any such plot
though.

Cheers,

-- 
Seb

______________________________________________
R-help@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.

Reply via email to