[S] multiple symbols in a single graph -- solution

Matthew Wiener (mcw@ln.nimh.nih.gov)
Fri, 18 Sep 1998 12:45:08 -0400 (EDT)


Two ways to put multiple symbols:

1. "old" graphics

plot(x, y, type = "n") # axes only
text(x, y, sym[g]) # does the plot (where g is a variable defining the
groups, possibly a factor)

2. Trellis graphs

use panel.superpose:

xyplot(Life.Exp~Murder, panel=panel.superpose, groups=Region,data=d,
pch=c("N","S","M","W"))

Thanks to Bill Venables and Bill Dunlap.

Matt Wiener

-----------------------------------------------------------------------
This message was distributed by s-news@wubios.wustl.edu. To unsubscribe
send e-mail to s-news-request@wubios.wustl.edu with the BODY of the
message: unsubscribe s-news