Skip to content

Latest commit

 

History

History
145 lines (92 loc) · 3.45 KB

README.md

File metadata and controls

145 lines (92 loc) · 3.45 KB

uiothemes

CRAN status R build status Travis build status

The goal of uiothemes is to provide branded templates for the University of Oslo for commonly used R markdown packages. Currently the package contains:

  • Presentation template for the xaringan-package
  • Tutorial template for the learnr-package
  • Website template for the distill-package
  • Article template for the distill-package
  • Themes for the ggplot2-package
  • Colour and fill scales for the ggplot2-package

Installation

You can install uiothemes from github

# install.packages("remotes")
remotes::install_github("Athanasiamo/uiothemes")

Basic use

xaringan presentation, learnr tutorial and distill article templates with UiO branding can be access easily using the RStudio IDE, by selecting File -> R markdown ... -> From Template.

Distill website template can be access most easily through the RStudio IDE to create a new project. File -> New project... -> New Directory -> UiO Distill Website

Previews

Distill article

Distill article

Xaringan presentation

Xaringan presentation

Learnr tutorial

Learnr tutorial

Distill website

Distill website

ggplot2 branding

The ggplot branding is applied through themes and scales.

library(uiothemes)
library(ggplot2)

ggplot(mtcars, aes(mpg, disp, colour = cyl)) +
  geom_point(size = 5) +
  scale_colour_uio(discrete = FALSE) +
  theme_uio() +
  labs(title = "The fonts and colours are UiO specific",
       subtitle = "and can provide coherent plot branding")

ggplot(mtcars, aes(mpg, disp, colour = cyl)) +
  geom_point(size = 5) +
  scale_colour_uio(palette = "redwhite", discrete = FALSE) +
  theme_uio_dark() +
  labs(title = "The fonts and colours are UiO specific",
       subtitle = "and can provide coherent plot branding")