class: monash-bg-blue center middle hide-slide-number <div class="bg-black white" style="width:45%;right:0;bottom:0;padding-left:5px;border: solid 4px white;margin: auto;"> <i class="fas fa-exclamation-circle"></i> These slides are viewed best by Chrome and occasionally need to be refreshed if elements did not load properly. See here for <a href=part1-session0.pdf>PDF <i class="fas fa-file-pdf"></i></a>. </div> <br> .white[Push the **right arrow key** to see the next slide.] --- count: false background-image: url(images/bg4.jpg) background-size: cover class: hide-slide-number title-slide <div class="grid-row" style="grid: 1fr / 2fr;"> .item.center[ # <span style="text-shadow: 2px 2px 30px white;">Data Visualisation with R</span> <!-- ## <span style="color:yellow;text-shadow: 2px 2px 30px black;">Getting started</span> --> ] .center.shade_black.animated.bounceInUp.slower[ <br><br> ## Getting started <br> Presented by Emi Tanaka & Di Cook Department of Econometrics and Business Statistics <img src="images/monash-one-line-reversed.png" style="width:500px"><br>
<i class="fas fa-envelope faa-float animated "></i>
emi.tanaka@monash.edu
<i class="fab fa-twitter faa-float animated faa-fast "></i>
@statsgen .bottom_abs.width100.bg-black[ 21st Feb 2022 @ methods@manchester | Zoom ] ] </div> --- .flex.h-100[ .w-30.pa3.monash-bg-blue.white.border-right[ .circle-image[ <center> <img src="images/avatar.png" width = "150px"/> </center> ] <br> **Emi Tanaka** *Lecturer in Statistics* Monash University <br> .f3[ <i class="fas fa-globe"></i> https://emitanaka.org/ <i class="fas fa-envelope"></i> emi.tanaka@monash.edu <i class="fab fa-twitter"></i> @statsgen ] ] .w-70.pl3[ # About your instructor * I am an academic at Monash Univeristy in Australia * I teach R at university courses as well as use it daily for research and hobby <i class="fab fa-reddit-alien"></i> * Lately, I've been working on automating the visualisation of experimental designs made using the `edibble` R-package. .flex.f6[ .w-60.pr3[ ```r library(edibble) life <- design("Lifestyle experiment") %>% set_units(person = 40) %>% set_trts(diet = c("Atkins", "Paleo", "Low-Carb"), exercise = c("light", "heavy")) %>% allot_table(diet:exercise ~ person) life ``` ``` ## # Lifestyle experiment ## # An edibble: 40 x 3 ## person diet exercise ## <unit(40)> <trt(3)> <trt(2)> ## 1 person1 Paleo heavy ## 2 person2 Paleo heavy ## 3 person3 Low-Carb light ## 4 person4 Low-Carb heavy ## 5 person5 Low-Carb heavy ## 6 person6 Low-Carb heavy ## 7 person7 Low-Carb heavy ## 8 person8 Atkins heavy ## 9 person9 Low-Carb heavy ## 10 person10 Low-Carb light ## # โฆ with 30 more rows ``` ] .w-40.pr3[ ```r library(deggust) autoplot(life) ``` <!-- --> ]] ] ] --- .flex.h-100[ .w-30.pa3.monash-bg-blue.white.border-right[ .circle-image[ <center> <img src="http://dicook.org/img/dicook-2019.png" width = "150px"/> </center> ] <br> **Di Cook** *Professor of Business Analytics* Monash University <br> .f3[ <i class="fas fa-globe"></i> https://dicook.org/ <i class="fas fa-envelope"></i> dicook@monash.edu <i class="fab fa-twitter"></i> @visnut ] ] .w-70.pl3[ # About your instructor * In July 2015 I moved home to Australia after many years of education and work in the USA * I have been using R since it first emerged from Auckland, NZ in 1995, and I am an elected member of the R Foundation
<i class="fas fa-quidditch faa-spin animated-hover "></i>
* I am one of four editors of the R Journal editorial team that publishes articles about R packages
<i class="fas fa-book faa-tada animated-hover "></i>
* My main statistical application areas are sports, ecology and bioinformatics; and I like to develop new software ]] --- .flex.h-100[ .w-30.pa3.monash-bg-blue.white.border-right[ .circle-image[ <center> <img src="images/daidai.jpg" width = "200px"/> </center> ] <br> **Danyang Dai** *Research & Teaching Assistant* Monash University <br> .f4[ <i class="fas fa-globe"></i> https://dai.netlify.app/ <i class="fas fa-envelope"></i> Danyang.Dai@monash.edu <i class="fab fa-twitter"></i> @Daidaidai2014 ] ] .w-70.pl3[ # About your helper * I am a Research/Teaching Assistant at Monash. I teach Data visualisation and Statistical Thinking. * I volunteer at R-Ladies Melbourne and presented workshops about R Markdown and Blogdown. * I am currently developing introduction to R materials with Emi and working on CYCLED Study at the School of Public Health and Preventive Medicine. ]] --- class: center middle <i class="fas fa-user-alt monash-blue font_large animated bounce"></i> .font_large.monash-blue[Introduce yourself in the chat!] <br> What's your profession? Where do you live? What's your hobby? What's would you like for people to know about you? --- # Schedule for **Part 1** <br> Time | Activity :----|:--- 8.45-9.00 | Registration + Installation Help 9.00-9.30 | **Lesson 1:** Getting started with grammar of graphics 9.30-9.45 | *Break out session* 9.45-10.15 | **Lesson 2:** Multiple layers, facetting and tidying your data 10.15-10.30 | *Break out session* 10.30-11.00 | *Coffee Break* 11.00-11.30 | **Lesson 3:** Scales and color 11.30-11.45 | *Break out session* 11.45-12.15 | **Lesson 4:** Publication-ready plots 12.15-12.30 | *Break out session* --- # Schedule for **Part 2** <br> Time | Activity :----|:--- 9.00-9.30 | **Lesson 1:** Check your `ggplot2` knowledge 9.30-9.45 | *Break out session* 9.45-10.15 | **Lesson 2:** Making maps 10.15-10.30 | *Break out session* 10.30-11.00 | *Coffee Break* 11.00-11.30 | **Lesson 3:** Getting your plots to talk back 11.30-11.45 | *Break out session* 11.45-12.15 | **Lesson 4:** Determining best plot design 12.15-12.30 | *Break out session* + Conclusion --- # Getting Started .center[ .blue.font_large[<i class="fas fa-globe"></i> http://emitanaka.org/datavis-workshop/] ] .info-box[ .red[**If you had any issues installing any packages or software**] go to:<br> .center[ .blue[<i class="fas fa-link"></i> https://rstudio.cloud/project/1487877] ] and save a permanent copy to your RStudio Cloud account for the R exercises. ] .center[ .font_large[<i class="fas fa-download"></i> Click [here](https://github.com/emitanaka/datavis-workshop/archive/refs/heads/master.zip) to download all materials as a ZIP file.] ] --- class: center # Help me! <br><br> You can write in the chat. <br> You can ask (unmute yourself). <br> You can raise hand from zoom under Participants. <img src="images/zoom-help.png"> <br> We'll come around in breakout sessions. --- class: font_smaller background-color: #e5e5e5 # Session Information .scroll-350[ ```r devtools::session_info() ``` ``` ## โ Session info ๐ฉโ๐งโ๐ฆ ๐ ๐ โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ ## hash: family: woman, girl, boy, elevator, bright button ## ## setting value ## version R version 4.1.2 (2021-11-01) ## os macOS Big Sur 11.6.2 ## system x86_64, darwin17.0 ## ui RStudio ## language (EN) ## collate en_AU.UTF-8 ## ctype en_AU.UTF-8 ## tz Australia/Melbourne ## date 2022-02-20 ## rstudio 2022.02.0-preview+392 Prairie Trillium (desktop) ## pandoc 2.17.1.1 @ /usr/local/bin/ (via rmarkdown) ## ## โ Packages โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ ## ! package * version date (UTC) lib source ## AlgDesign 1.2.0 2019-11-29 [1] CRAN (R 4.1.0) ## anicon 0.1.0 2021-11-30 [1] Github (emitanaka/anicon@0b756df) ## assertthat 0.2.1 2019-03-21 [1] CRAN (R 4.1.0) ## bslib 0.3.1 2021-10-06 [1] CRAN (R 4.1.0) ## cachem 1.0.6 2021-08-19 [1] CRAN (R 4.1.0) ## callr 3.7.0 2021-04-20 [1] CRAN (R 4.1.0) ## V cli 3.1.1 2022-02-14 [1] CRAN (R 4.1.2) (on disk 3.2.0) ## colorspace 2.0-2 2021-06-24 [1] CRAN (R 4.1.0) ## V crayon 1.4.2 2022-02-14 [1] CRAN (R 4.1.2) (on disk 1.5.0) ## curl 4.3.2 2021-06-23 [1] CRAN (R 4.1.0) ## DBI 1.1.1 2021-01-15 [1] CRAN (R 4.1.0) ## deggust * 0.0.0.9000 2022-02-20 [1] Github (emitanaka/deggust@539a6af) ## desc 1.4.0 2021-09-28 [1] CRAN (R 4.1.0) ## devtools 2.4.2 2021-06-07 [1] CRAN (R 4.1.0) ## digest 0.6.29 2021-12-01 [1] CRAN (R 4.1.0) ## dplyr 1.0.7 2021-06-18 [1] CRAN (R 4.1.0) ## DT 0.20 2021-11-15 [1] CRAN (R 4.1.0) ## edibble * 0.0.0.9000 2022-02-20 [1] Github (emitanaka/edibble@b56425a) ## ellipsis 0.3.2 2021-04-29 [1] CRAN (R 4.1.0) ## evaluate 0.14 2019-05-28 [1] CRAN (R 4.1.0) ## fansi 1.0.2 2022-01-14 [1] CRAN (R 4.1.2) ## farver 2.1.0 2021-02-28 [1] CRAN (R 4.1.0) ## fastmap 1.1.0 2021-01-25 [1] CRAN (R 4.1.0) ## fs 1.5.2 2021-12-08 [1] CRAN (R 4.1.0) ## generics 0.1.2 2022-01-31 [1] CRAN (R 4.1.2) ## ggnewscale 0.4.6 2022-02-15 [1] CRAN (R 4.1.2) ## ggplot2 * 3.3.5 2021-06-25 [1] CRAN (R 4.1.0) ## glue 1.6.1 2022-01-22 [1] CRAN (R 4.1.2) ## gtable 0.3.0 2019-03-25 [1] CRAN (R 4.1.0) ## highr 0.9 2021-04-16 [1] CRAN (R 4.1.0) ## htmltools 0.5.2 2021-08-25 [1] CRAN (R 4.1.0) ## htmlwidgets 1.5.4 2021-09-08 [1] CRAN (R 4.1.0) ## httpuv 1.6.4 2021-12-14 [1] CRAN (R 4.1.0) ## icon 0.1.0 2021-11-30 [1] Github (emitanaka/icon@8458546) ## jquerylib 0.1.4 2021-04-26 [1] CRAN (R 4.1.0) ## jsonlite 1.7.3 2022-01-17 [1] CRAN (R 4.1.2) ## knitr 1.37 2021-12-16 [1] CRAN (R 4.1.0) ## labeling 0.4.2 2020-10-20 [1] CRAN (R 4.1.0) ## later 1.3.0 2021-08-18 [1] CRAN (R 4.1.0) ## lifecycle 1.0.1 2021-09-24 [1] CRAN (R 4.1.0) ## magrittr 2.0.2 2022-01-26 [1] CRAN (R 4.1.2) ## memoise 2.0.0 2021-01-26 [1] CRAN (R 4.1.0) ## mime 0.12 2021-09-28 [1] CRAN (R 4.1.0) ## munsell 0.5.0 2018-06-12 [1] CRAN (R 4.1.0) ## nestr 0.1.2 2022-02-01 [1] CRAN (R 4.1.2) ## openxlsx 4.2.4 2021-06-16 [1] CRAN (R 4.1.0) ## pillar 1.7.0 2022-02-01 [1] CRAN (R 4.1.2) ## pkgbuild 1.2.0 2020-12-15 [1] CRAN (R 4.1.0) ## pkgconfig 2.0.3 2019-09-22 [1] CRAN (R 4.1.0) ## pkgload 1.2.3 2021-10-13 [1] CRAN (R 4.1.0) ## prettyunits 1.1.1 2020-01-24 [1] CRAN (R 4.1.0) ## processx 3.5.2 2021-04-30 [1] CRAN (R 4.1.0) ## promises 1.2.0.1 2021-02-11 [1] CRAN (R 4.1.0) ## prompt 1.0.1 2021-03-12 [1] CRAN (R 4.1.0) ## ps 1.6.0 2021-02-28 [1] CRAN (R 4.1.0) ## purrr 0.3.4 2020-04-17 [1] CRAN (R 4.1.0) ## R6 2.5.1 2021-08-19 [1] CRAN (R 4.1.0) ## Rcpp 1.0.8 2022-01-13 [1] CRAN (R 4.1.2) ## remotes 2.4.1 2021-09-29 [1] CRAN (R 4.1.0) ## V rlang 1.0.0 2022-02-03 [1] CRAN (R 4.1.2) (on disk 1.0.1) ## rmarkdown 2.11 2021-09-14 [1] CRAN (R 4.1.0) ## rprojroot 2.0.2 2020-11-15 [1] CRAN (R 4.1.0) ## rstudioapi 0.13 2020-11-12 [1] CRAN (R 4.1.0) ## sass 0.4.0 2021-05-12 [1] CRAN (R 4.1.0) ## scales 1.1.1 2020-05-11 [1] CRAN (R 4.1.0) ## servr 0.24 2021-11-16 [1] CRAN (R 4.1.2) ## sessioninfo 1.2.1 2021-11-02 [1] CRAN (R 4.1.0) ## simulate 0.0.0.9000 2022-01-13 [1] local ## stringi 1.7.6 2021-11-29 [1] CRAN (R 4.1.0) ## stringr 1.4.0 2019-02-10 [1] CRAN (R 4.1.0) ## testthat 3.1.0 2021-10-04 [1] CRAN (R 4.1.0) ## tibble 3.1.6 2021-11-07 [1] CRAN (R 4.1.0) ## tidyselect 1.1.1 2021-04-30 [1] CRAN (R 4.1.0) ## usethis 2.1.5 2021-12-09 [1] CRAN (R 4.1.0) ## utf8 1.2.2 2021-07-24 [1] CRAN (R 4.1.0) ## vctrs 0.3.8 2021-04-29 [1] CRAN (R 4.1.0) ## viridisLite 0.4.0 2021-04-13 [1] CRAN (R 4.1.0) ## withr 2.4.3 2021-11-30 [1] CRAN (R 4.1.0) ## xaringan 0.22 2021-06-23 [1] CRAN (R 4.1.0) ## xfun 0.29 2021-12-14 [1] CRAN (R 4.1.0) ## yaml 2.2.2 2022-01-25 [1] CRAN (R 4.1.2) ## zip 2.2.0 2021-05-31 [1] CRAN (R 4.1.0) ## ## [1] /Library/Frameworks/R.framework/Versions/4.1/Resources/library ## ## V โโ Loaded and on-disk version mismatch. ## ## โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ ``` ] These slides are licensed under <br><center><a href="https://creativecommons.org/licenses/by-sa/3.0/au/"><img src="images/cc.svg" style="height:2em;"/><img src="images/by.svg" style="height:2em;"/><img src="images/sa.svg" style="height:2em;"/></a></center>