Nothing
plot_activity_presence <- function(x, ...) {
mapping <- attr(x, "mapping")
relative <- NULL
x %>%
ggplot(aes_string(glue::glue("reorder({mapping$activity_id}, relative)"), "relative")) +
geom_col(aes(fill = relative)) +
scale_fill_continuous_tableau(name = "Activity Presence", palette = "Blue")+
theme_light() +
coord_flip() +
labs(x = "Activity", y = "Relative Activity Presence") -> p
if(!is.null(mapping$groups)) {
p <- p + facet_grid(as.formula(paste(c(paste(mapping$groups, collapse = "+"), "~." ), collapse = "")), scales = "free_y")
}
return(p)
}
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.