---
title: "Visualizing Data (in R)"
subtitle: "An opinionated style guide
"
author: "
June Choe"
date: '2021-02-10'
output:
xaringan::moon_reader:
lib_dir: libs
css: [default, hygge, ninjutsu, "custom.css"]
nature:
ratio: 16:10
highlightStyle: 'solarized-light'
highlightLines: true
countIncrementalSlides: false
editor_options:
chunk_output_type: console
---
class: middle, center
```{r setup, echo = FALSE, message = FALSE, warning = FALSE}
library(tidyverse)
library(Cairo)
library(flipbookr)
library(xaringan)
library(xaringanExtra)
xaringanExtra::use_search(show_icon = TRUE)
knitr::opts_chunk$set(message = FALSE, warning = FALSE, comment = " ", cache = FALSE, dev = "CairoSVG")
set.seed(1234)
```
```{r, echo=FALSE, out.width="650px",out.height="400px", fig.cap="https://xkcd.com/1945"}
knitr::include_graphics("https://imgs.xkcd.com/comics/scientific_paper_graph_quality.png")
```
---
# Motivation
--
**Why bother improving the quality of your plot?**
--
-
Helps people remember your results better
-- - Makes your findings look more **credible** -- - Increases the chance of your work being **shared** -- - Shows **respect** for your audienceShare practical, language-agnostic tips for improving readability & accessibility
-- - Walk through implementations of these ideas (w/ [R code](https://raw.githubusercontent.com/yjunechoe/sandbox/master/flipbooks/ggplot2_master/feb_2020_ggplot2.Rmd)) -- - Demonstrate that the _design_ just as important as the content --- # Outline -- **Four principles for explanatory data visualization** -- -Make your text readable
-- - Be generous about **margins and spacing** -- - Make the **legend** clear but subtle -- - Make **color** easy on your reader's eyes --