Communicating with Data in the Tidyverse
Timo Grossenbacher
Data Journalist
ggplot(plot_data) +
geom_histogram(aes(
x = working_hours)) +
labs(x = "Working hours per week",
y = "Number of countries") +
theme(
text = element_text(
family = "Bookman",
color = "gray25")
)
ggplot(plot_data) +
geom_histogram(aes(
x = working_hours)) +
labs(x = "Working hours per week",
y = "Number of countries") +
theme_classic()
ggplot(plot_data) +
geom_histogram(aes(
x = working_hours)) +
labs(x = "Working hours per week",
y = "Number of countries") +
theme_classic() +
theme(
text = element_text(
family = "Bookman",
color = "gray25")
)
?theme
axis.title
label of axes (element_text; inherits from text)
axis.title.x
x axis label (element_text; inherits from axis.title)
axis.title.x.top
x axis label on top axis (element_text; inherits from axis.title.x)
axis.title.x.bottom
x axis label on bottom axis (element_text; inherits from axis.title.x)
element_text()
element_rect()
element_line()
element_blank()
ggplot(plot_data) +
geom_histogram(aes(
x = working_hours)) +
labs(x = "Working hours per week",
y = "Number of countries") +
theme(
text = element_blank()
)
Communicating with Data in the Tidyverse