knitr::opts_chunk$set( collapse = TRUE, comment = "#>" )
library(vikingR) library(tidyverse, quietly = TRUE) theme_set(theme_minimal())
ggplot(iris, aes(Sepal.Width, Sepal.Length, color = Species)) + geom_point(size = 4) + scale_colour_viking()
ggplot(iris, aes(Sepal.Width, Sepal.Length, color = Sepal.Length)) + geom_point(size = 4, alpha = .6) + scale_colour_viking(discrete = FALSE, palette = "Gul")
data("topNorName1880to2020") topNorName1880to2020%>% ggplot(aes(reorder(name,n),n, fill=name)) + geom_histogram(stat="identity") + scale_fill_viking(palette = "Alle", guide = "none")+ labs(x="", y= "Frequency in the top 10 boys names in Norway")+ coord_flip()+ theme_classic()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.