Re: [R] use different symbols for frequency in a plot

From: Chuck Cleland <ccleland_at_optonline.net>
Date: Tue 09 Aug 2005 - 05:17:44 EST

You might consider one of these approaches instead:

plot(jitter(x), jitter(y))

or

pdf(file="c:/AlphaExample.pdf", version = "1.4")

plot(x, y, col = rgb(1, 0, 0, .2), pch = 16)

dev.off()

Kerry Bush wrote:
> suppose I have the following data
>
> x<-c(rep(.1,5),rep(.2,6),rep(.4,10),rep(.5,20))
> y<-c(rep(.5,3),rep(.6,8),rep(1.2,8),rep(2.5,18),rep(3,4))
>
> If I plot(x,y) in R, I will only get seven distinct
> points. What I want to do is to use different symbols
> to show the frequency at each point.
>
> e.g. if the frequncey is between 1 and 5, then I plot
> the point as a circle; if the frequency is between 6
> and 10, then I plot the point as a square; if the
> frequency is above 10, then I plot the point as a
> triangle.
>
> I am not sure how to do this in R. Can anybody help me?
>
> ______________________________________________
> R-help@stat.math.ethz.ch mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
>

-- 
Chuck Cleland, Ph.D.
NDRI, Inc.
71 West 23rd Street, 8th floor
New York, NY 10010
tel: (212) 845-4495 (Tu, Th)
tel: (732) 452-1424 (M, W, F)
fax: (917) 438-0894

______________________________________________
R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Received on Tue Aug 09 05:21:22 2005

This archive was generated by hypermail 2.1.8 : Fri 03 Mar 2006 - 03:39:45 EST