Changing graphics font sizes in .Rpres

Nicholas G Reich
6 July 2016

Slide With Base Graphics Plot (no font adjustment)

plot(cars)

plot of chunk unnamed-chunk-1

Slide With Base Graphics Plot (with font adjustment)

par(cex=2.5, mar=c(4,4,1,1))
plot(cars)

plot of chunk unnamed-chunk-2

Slide With ggplot (no font adjustment)

library(ggplot2)
ggplot(cars) + geom_point(aes(x=speed, y=dist))

plot of chunk unnamed-chunk-3

Slide With ggplot (with font adjustment)

ggplot(cars) + geom_point(aes(x=speed, y=dist)) + 
  theme(text=element_text(size = 36))

plot of chunk unnamed-chunk-4