hello guys:
so far I have found quick and easy success: ggplot installed w its dependencies and I used it to do a quick and pretty grap, which I saved you from having to see, although I wouldn't be sure how to include it.
I had to install and load hexbin.
I think I am understanfding that I will need to install each package I have used so far?
thanks so much for your help.
stephen
version 3.5.1 (2018-07-02) -- "Feather Spray"
Copyright (C) 2018 The R Foundation for Statistical Computing
Platform: x86_64-apple-darwin15.6.0 (64-bit)
R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.
Natural language support but running in an English locale
R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.
Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.
[Workspace loaded from ~/.RData]
> install.packages("ggplot2")
also installing the dependencies ‘glue’, ‘magrittr’, ‘stringi’, ‘colorspace’, ‘assertthat’, ‘fansi’, ‘utf8’, ‘Rcpp’, ‘stringr’, ‘labeling’, ‘munsell’, ‘R6’, ‘RColorBrewer’, ‘cli’, ‘crayon’, ‘pillar’, ‘digest’, ‘gtable’, ‘lazyeval’, ‘plyr’, ‘reshape2’, ‘rlang’, ‘scales’, ‘tibble’, ‘viridisLite’, ‘withr’
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/glue_1.3.0.tgz'
Content type 'application/x-gzip' length 93553 bytes (91 KB)
==================================================
downloaded 91 KB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/magrittr_1.5.tgz'
Content type 'application/x-gzip' length 152395 bytes (148 KB)
==================================================
downloaded 148 KB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/stringi_1.2.4.tgz'
Content type 'application/x-gzip' length 13584342 bytes (13.0 MB)
==================================================
downloaded 13.0 MB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/colorspace_1.3-2.tgz'
Content type 'application/x-gzip' length 516228 bytes (504 KB)
==================================================
downloaded 504 KB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/assertthat_0.2.0.tgz'
Content type 'application/x-gzip' length 52476 bytes (51 KB)
==================================================
downloaded 51 KB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/fansi_0.4.0.tgz'
Content type 'application/x-gzip' length 207507 bytes (202 KB)
==================================================
downloaded 202 KB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/utf8_1.1.4.tgz'
Content type 'application/x-gzip' length 193968 bytes (189 KB)
==================================================
downloaded 189 KB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/Rcpp_1.0.0.tgz'
Content type 'application/x-gzip' length 4535632 bytes (4.3 MB)
==================================================
downloaded 4.3 MB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/stringr_1.3.1.tgz'
Content type 'application/x-gzip' length 186353 bytes (181 KB)
==================================================
downloaded 181 KB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/labeling_0.3.tgz'
Content type 'application/x-gzip' length 60579 bytes (59 KB)
==================================================
downloaded 59 KB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/munsell_0.5.0.tgz'
Content type 'application/x-gzip' length 240174 bytes (234 KB)
==================================================
downloaded 234 KB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/R6_2.3.0.tgz'
Content type 'application/x-gzip' length 55479 bytes (54 KB)
==================================================
downloaded 54 KB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/RColorBrewer_1.1-2.tgz'
Content type 'application/x-gzip' length 52941 bytes (51 KB)
==================================================
downloaded 51 KB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/cli_1.0.1.tgz'
Content type 'application/x-gzip' length 574111 bytes (560 KB)
==================================================
downloaded 560 KB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/crayon_1.3.4.tgz'
Content type 'application/x-gzip' length 750568 bytes (732 KB)
==================================================
downloaded 732 KB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/pillar_1.3.0.tgz'
Content type 'application/x-gzip' length 151337 bytes (147 KB)
==================================================
downloaded 147 KB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/digest_0.6.18.tgz'
Content type 'application/x-gzip' length 187193 bytes (182 KB)
==================================================
downloaded 182 KB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/gtable_0.2.0.tgz'
Content type 'application/x-gzip' length 85683 bytes (83 KB)
==================================================
downloaded 83 KB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/lazyeval_0.2.1.tgz'
Content type 'application/x-gzip' length 152654 bytes (149 KB)
==================================================
downloaded 149 KB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/plyr_1.8.4.tgz'
Content type 'application/x-gzip' length 946407 bytes (924 KB)
==================================================
downloaded 924 KB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/reshape2_1.4.3.tgz'
Content type 'application/x-gzip' length 286207 bytes (279 KB)
==================================================
downloaded 279 KB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/rlang_0.3.0.1.tgz'
Content type 'application/x-gzip' length 1074996 bytes (1.0 MB)
==================================================
downloaded 1.0 MB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/scales_1.0.0.tgz'
Content type 'application/x-gzip' length 701217 bytes (684 KB)
==================================================
downloaded 684 KB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/tibble_1.4.2.tgz'
Content type 'application/x-gzip' length 230077 bytes (224 KB)
==================================================
downloaded 224 KB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/viridisLite_0.3.0.tgz'
Content type 'application/x-gzip' length 57149 bytes (55 KB)
==================================================
downloaded 55 KB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/withr_2.1.2.tgz'
Content type 'application/x-gzip' length 151252 bytes (147 KB)
==================================================
downloaded 147 KB
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/ggplot2_3.1.0.tgz'
Content type 'application/x-gzip' length 3622365 bytes (3.5 MB)
==================================================
downloaded 3.5 MB
The downloaded binary packages are in
/var/folders/nl/7dfp7f693yb87ntg7qd70s7c0000gn/T//RtmpfV1cFd/downloaded_packages
> library("ggplot2", lib.loc="/Library/Frameworks/R.framework/Versions/3.5/Resources/library")
> install.packages("hexbin")
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.5/hexbin_1.27.2.tgz'
Content type 'application/x-gzip' length 838355 bytes (818 KB)
==================================================
downloaded 818 KB
The downloaded binary packages are in
/var/folders/nl/7dfp7f693yb87ntg7qd70s7c0000gn/T//RtmpfV1cFd/downloaded_packages
> library("hexbin", lib.loc="/Library/Frameworks/R.framework/Versions/3.5/Resources/library")
> ggplot(F4verl, aes(px, pz)) +
+ geom_point() +
+ facet_wrap(~ batter_hand) +
+ coord_equal() +
+ geom_path(aes(x, y), data = kZone, lwd = 2, col = "white")
> ggplot(F4verl, aes(px, pz)) +
+ stat_binhex() +
+ facet_wrap(~ batter_hand) +
+ coord_equal() +
+ geom_path(aes(x, y), data = kZone, lwd = 2, col = "white", alpha = .3)
>
>