plotting magnitude
On Dec 18, 2007 2:06 PM, <dkowalske at umassd.edu> wrote:
I am plotting fishing vessel positions and want these points to be
relative in size to the catch at that point. Is this possible? I am just
begining to use R and my search of the help section didnt help in this
area. Heres what Im using so far
xyplot(data$latdeg~data$londeg |vessek , groups=vessek,
xlim=rev(range(69:77)),ylim=(range(35:42)), data=data,
main=list ("Mackerel catches", cex=1.0),
ylab="latitude", notch=T, varwidth=T,
xlab="longitude", cex.axis=0.5,)
any info would be appreciated
This is pretty easy to do with the ggplot2 package: library(ggplot2) qplot(longdeg, latdeg, data = data, facets = . ~ vessek, size = catch) or maybe qplot(longdeg, latdeg, data = data, facets = . ~ vessek, size = catch) + scale_area() if you want the area of the points proportional to the catch, rather than their radius Hadley