knitr::opts_chunk$set( collapse = TRUE, comment = "#>", fig.path = "man/figures/README-", out.width = "100%", warning = FALSE, cache = TRUE )
The goal of lockeutils is to provide some common tools to the Locke Data team.
remotes::install_github("lockedata/lockeutils")
And then re-start your R session.
At the first package loading, lockeutils
should guide you to install fonts. We'll update instructions here based on your experience.
library("ggplot2") library("lockeutils") df <- data.frame( gp = factor(rep(letters[1:3], each = 10)), y = rnorm(30) ) ggplot(df, aes(gp, y)) + geom_point() + ggtitle("wow title LHS great", subtitle = "nice plot") + theme_ld()
For no more than 3 classes.
ggplot(mtcars, aes(factor(cyl), fill = factor(vs))) + geom_bar() + theme_ld() + scale_fill_ld() ggplot(iris, aes(Sepal.Length, Sepal.Width, color = Species)) + geom_point() + theme_ld() + scale_color_ld() ggplot(diamonds[diamonds$color %in% unique(diamonds$color)[1:6],]) + geom_point(aes(x = carat, y = price, color = color)) + theme_ld() + scale_color_ld()
lockeutils::get_ld_colours()
Wanna report a bug or suggest a feature? Great stuff! For more information on how to contribute check out our contributing guide.
Please note that this R package is released with a Contributor Code of Conduct. By participating in this package project you agree to abide by its terms.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.