ggpres: Adjust test size on a ggplot to make it visible in...

View source: R/ggpres.R

ggpresR Documentation

Adjust test size on a ggplot to make it visible in presentations

Description

Change the size of text on a ggplot so that a plot designed to look good in print is readable when included in a slide in a presentation (or vice verse)

Usage

ggpres(g, title_size = 24, text_size = 18)

Arguments

g

A ggplot graph

title_size

The font size for the title, legend title and axes titles

text_size

The font size for for the axis lables, legend text and facet text

Value

A ggplot graph

Author(s)

Ella Kaye

Examples


library(ggplot2)
g <- ggplot(mpg, aes(displ, hwy)) +
 geom_point() +
 facet_wrap(~class, scales = "free") +
 ggtitle("A faceted plot")
g2 <- ggpres(g)
g2 + geom_point(size = 2)

EllaKaye/EMK documentation built on Jan. 7, 2023, 3:24 p.m.