[R] Seeking advice on lattice package in R2.4.0 concerning stripplot

Dr L. Y Hin lyhin at netvigator.com
Sat Dec 16 02:22:15 CET 2006


Dear all,

I am using the R 2.4.0 environment on Windows XP SP2 
machine and trying to use the lattice package version 
0.14-9 which you have kindly written to share with the 
R community.

I have a question concerning the stripplot which I'd be very
grateful if you can kindly advise me on:

I used the dataset called trydata to plot a graph using
stripplot (dataset attached), and the scripts used to 
procude the plot is as follows:

trydata<-dget("trydata")
stripplot(Position~Count|y*Grouping,jitter=T,group=subtype,
data=trydata,xlab="Count rate (%)",
pch=c(0,3,6,5),
key=list(text=list(c("GS in front", "GS at the back",
"MS in front","MS at the back")),
points = Rows(trellis.par.get("superpose.symbol"),1:4),
columns=2))

When I plotted the graph and viewed it on
R, the legend and the datapoint shapes are
correct. However, when I export it into .pdf
form using the pulldown menu in R, the legend for 
"GS in front" is incorrect. 
Instead if being a prism, it became
a circle. How can I get around this?
I've attached the figure thus generated in pdf form
for your kind consideration.

Specifically, how can I modify the specifications in the
command to produce the correct pch type in the legend 
as in the chart itself?

Thank you very much in advance for your kind advice.

Best
Lin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: trydatafigure.pdf
Type: application/pdf
Size: 13614 bytes
Desc: not available
Url : https://stat.ethz.ch/pipermail/r-help/attachments/20061216/c233eaae/attachment.pdf 


More information about the R-help mailing list