-
Notifications
You must be signed in to change notification settings - Fork 10
/
README.Rmd
189 lines (124 loc) · 7.02 KB
/
README.Rmd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
---
output: github_document
---
<!-- README.md is generated from README.Rmd. Please edit that file -->
```{r setup, include = FALSE}
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
fig.path = "man/figures/README-",
out.width = "70%",
fig.align = "center"
)
```
# tvthemes 1.3.1 <img src="man/figures/logo.png" align="right" style="padding-left:10px;background-color:white;" />
<!-- badges: start -->
[![Lifecycle: maturing](https://img.shields.io/badge/lifecycle-maturing-blue.svg)](https://lifecycle.r-lib.org/articles/stages.html)
[![CRAN\_Status\_Badge](http://www.r-pkg.org/badges/version/tvthemes)](https://CRAN.R-project.org/package=tvthemes)
[![Downloads](http://cranlogs.r-pkg.org/badges/tvthemes)](https://cran.r-project.org/package=tvthemes)
[![License: GPL v3](https://img.shields.io/badge/License-GPLv3-blue.svg)](https://www.gnu.org/licenses/gpl-3.0)
[![Coverage status](https://codecov.io/gh/Ryo-N7/tvthemes/branch/master/graph/badge.svg)](https://app.codecov.io/gh/Ryo-N7/tvthemes?branch=master/)
[![R build status](https://github.com/Ryo-N7/tvthemes/workflows/R-CMD-check/badge.svg)](https://github.com/Ryo-N7/tvthemes/actions)
[![ko-fi](https://ko-fi.com/img/githubbutton_sm.svg)](https://ko-fi.com/O4O342A2A)
<!-- badges: end -->
Ryo Nakagawara | Twitter: `@R_by_Ryo`
The `tvthemes` package is a collection of various `ggplot2` themes and color/fill palettes based on everybody's favorite TV shows. What kick-started this whole package was my [blogpost](https://ryo-n7.github.io/2019-02-15-visualize-brooklyn-nine-nine/) looking at simple TV stats on my current favorite TV show, Brooklyn Nine-Nine. I got a lot of good feedback on the colors I used for the custom `ggplot2` theme and color palettes so I decided to expand it to other shows that I love! Suggestions and Pull Requests for palettes/themes are welcome!
* [Package Website](https://ryo-n7.github.io/tvthemes/)
* [Intro to `tvthemes 0.0.0.9100` blog post](https://ryo-n7.github.io/2019-05-16-introducing-tvthemes-package/)
* [`tvthemes 1.0.0` & CRAN release blog post](https://ryo-n7.github.io/2019-09-06-tvthemes-CRAN-announcement/)
* [`tvthemes 1.1.0` & CRAN release blog post](https://ryo-n7.github.io/2019-11-04-tvthemes-1.1.0-announcement/)
* [`tvthemes 1.3.0` & CRAN release blog post](https://ryo-n7.github.io/2022-03-17-tvthemes-1.3.0-announcement/)
```{r b99header, eval=FALSE}
library(tvthemes)
library(ggplot2)
library(extrafont)
loadfonts(quiet = TRUE)
ggplot(mpg, aes(displ)) +
geom_histogram(aes(fill = class),
col = "black", size = 0.1,
binwidth = 0.1) +
scale_fill_brooklyn99(palette = "Dark") +
labs(title = "Do you know what it means to 'clap back', Raymond?",
subtitle = glue::glue("BE- {emo::ji('clap')} -CAUSE {emo::ji('clap')} I {emo::ji('clap')} DO {emo::ji('clap')} !"),
x = "Titles of Your Sex Tape",
caption = "Pizza bagels? Pizza rolls? Pizza poppers? Pizzaritos? Pizza pockets?") +
theme_brooklyn99(title.font = "Titillium Web",
text.font = "Calibri Light",
subtitle.size = 14)
```
![](man/figures/README-b99header-1.png)
## Current list of TV shows
- __Avatar: The Last Airbender__: theme + palettes (Fire Nation, Water Tribe, Earth Kingdom, & Air Nomads)
- __Brooklyn Nine-Nine__: theme + palettes (regular & dark)
- __Game of Thrones/A Song of Ice & Fire__: 'The Palettes of Ice & Fire' (currently: Stark, Baratheon (Stannis), Lannister, Tully, Targaryen, Martell, Greyjoy, Tyrell, Arryn, Manderly)
- __Rick & Morty__: theme + palette
- __Parks & Recreation__: two themes (light & dark) + palette
- __The Simpsons__: theme + palette
- __Spongebob Squarepants__: theme + palette + background images
- __Hilda__: Day, Dusk, Night themes + palettes
- __Attack on Titan__: palette
- __Kim Possible__: palette
- __Big Hero 6__: palette
- __Gravity Falls__: palette
- __Steven Universe__: palette
- _More in future releases..._
- _Development branch_: TBD...
## Installation
You can install `tvthemes` by:
```{r, eval=FALSE}
## install.packages(devtools)
## for development version:
devtools::install_github("Ryo-N7/tvthemes")
## v1.3.0 is available on CRAN!
install.packages("tvthemes")
```
Now available on [CRAN](https://CRAN.R-project.org/package=tvthemes)!
## tvthemes 1.0.0 Major Changes
See [vignette](https://ryo-n7.github.io/tvthemes/articles/tvthemes-1_0_0.html).
## Fonts & Colors
See [vignette](https://ryo-n7.github.io/tvthemes/articles/fonts-and-colors.html).
# Examples
You can find the code for all the examples below in the ["Examples" Vignette](https://ryo-n7.github.io/tvthemes/articles/examples.html) on the [Package Website](https://ryo-n7.github.io/tvthemes/).
## Brooklyn Nine-Nine
![b99d](man/figures/README-b99header-1.png)
![b99l](man/figures/b99regpal_plot.png)
## Spongebob Squarepants
![bobspog](man/figures/sponge_plot.png)
![bobspogbkg](man/figures/bobspog.bg.png)
## Game of Thrones: House Stark, Tully, Targaryen
![StarkTullyTargaryen](man/figures/starktullytargaryen.png)
## Game of Thrones: House Tyrell, Lannister, Greyjoy
![TyrellLannisterGreyjoy](man/figures/tyrelllannistergreyjoy.png)
## Game of Thrones: Arryn, Manderly, Martell
![ArrynManderlyMartell](man/figures/arrynmanderlymartell.png)
## Game of Thrones: Stannis Baratheon, The One True King
![stannis](man/figures/stannis.png)
## The Simpsons
![simpsons](man/figures/simpsons_plot.png)
## Rick and Morty
![randm](man/figures/rickmorty_plot.png)
## Avatar: The Last Airbender (Fire Nation, Air Nomads, Water Tribe, Earth Kingdom)
![tla](man/figures/lastairbender.png)
## Parks and Recreation
![pandr](man/figures/parksandrec_both.png)
## Attack on Titan
![aot](man/figures/attackontitan.png)
## Kim Possible
![KimPossible](man/figures/kimpossible.png)
## Big Hero 6
![bighero6](man/figures/bighero6.png)
## Hilda
![hilda](man/figures/hilda.png)
## Gravity Falls
![gravityfall](man/figures/gravityfalls.png)
## Steven Universe
![stevenuniverse](man/figures/stevenuniverse.png)
# Contributing
Please note that the `tvthemes` project is released with a [Contributor Code of Conduct](https://github.com/Ryo-N7/tvthemes/blob/master/CODE_OF_CONDUCT.md). By contributing to this project, you agree to abide by its terms.
# License
This code is released under the GPL v3 License - see the
[LICENSE.md](https://github.com/Ryo-N7/tvthemes/blob/master/LICENSE.md) file for details.
# Credits
Inspired by Matt Oldach's [{vaporwave}](https://github.com/moldach/vapoRwave/), Bob Rudis' [{hrbrthemes}](https://github.com/hrbrmstr/hrbrthemes/), Garrick Aden-Buie's [{ggpomological}](https://github.com/gadenbuie/ggpomological/), Ewen Henderson's [{ghibli}](https://github.com/ewenme/ghibli/), [rOpenSci](https://github.com/ropenscilabs/)'s [{ochRe}](https://github.com/hollylkirk/ochRe), & [Nathan Cunningham](http://www.nathancunn.com/2017-07-16-simpsons-characters/).
Hilda palettes from [Matt Shanks](https://www.mattshanks.com.au/colour-palette-reference-hilda/) and [ChevyRay](https://imgur.com/a/6oY8c6k).
["Some Time Later" font](https://github.com/ctrlcctrlv/some-time-later) courtesy of Frederick Brennan.