--
You received this message because you are subscribed to the ggplot2 mailing list.
Please provide a reproducible example: https://github.com/hadley/devtools/wiki/Reproducibility
To post: email ggp...@googlegroups.com
To unsubscribe: email ggplot2+u...@googlegroups.com
More options: http://groups.google.com/group/ggplot2
After updating to ggplot2_0.9.3, previous code used to make summary plots (using stat_summary) no longer work. I get the error message "Each group consist of only one observation. Do you need to adjust the group aesthetic?". My data has more than one observation for each group.
I've tried to recreate the error using the mtcars data.
Any suggestions on how to properly create these summary plots would be greatly appreciated.
p <- ggplot(mtcars, aes(cyl,hp, colour = factor(gear)))
p <- p + geom_point()
p <- p + stat_summary(aes(group = factor(gear)), fun.y = mean, geom = "line")
p
# geom_path: Each group consist of only one observation. Do you need to adjust the group aesthetic?
# sessionInfo()
# R version 2.15.2 (2012-10-26)
# Platform: x86_64-apple-darwin9.8.0/x86_64 (64-bit)
# locale:
# [1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8
# attached base packages:
# [1] stats graphics grDevices utils datasets methods base
# other attached packages:
# [1] reshape2_1.2.2 plyr_1.8 ggplot2_0.9.3 knitr_0.9
# loaded via a namespace (and not attached):
# [1] colorspace_1.2-0 dichromat_1.2-4 digest_0.6.0 evaluate_0.4.3
# [5] formatR_0.7 grid_2.15.2 gtable_0.1.2 labeling_0.1
# [9] MASS_7.3-22 munsell_0.4 proto_0.3-9.2 RColorBrewer_1.0-5
# [13] scales_0.2.3 stringr_0.6.2 tools_2.15.2
When I implement "install.packages(c("plyr", "ggplot2", "scales", "gtable")) ", I get this error message:
Error in library(plyr) : there is no package called ‘plyr’
Any thoughts about that?
Thanks!
When I implement "install.packages(c("plyr", "ggplot2", "scales", "gtable")) ", I get this error message:
Error in library(plyr) : there is no package called ‘plyr’
Any thoughts about that?
Thanks!
On Friday, December 7, 2012 7:28:23 PM UTC-6, Dennis Murphy wrote: