Skip to content

Instantly share code, notes, and snippets.

@tejseth
Created January 6, 2021 18:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tejseth/f34eb135e4043c12c3549c05265ea741 to your computer and use it in GitHub Desktop.
Save tejseth/f34eb135e4043c12c3549c05265ea741 to your computer and use it in GitHub Desktop.
ridges <- df_plays_cov %>%
filter(epa > -2) %>%
filter(epa < 2)
ggplot(ridges, aes(x = epa, y = most_freq_cov, fill = most_freq_cov)) +
geom_density_ridges() +
theme_ridges() +
labs(x = "EPA Allowed",
y = "Coverage",
title = "EPA Ridge for Each Coverage",
caption = "By Tej Seth | @mfbanalytics | Data from the Big Data Bowl") +
theme(
plot.title = element_text(size = 14, hjust = 0.5, face = "bold"),
legend.position = "None"
) +
geom_vline(xintercept = 0, color = "black", linetype = "solid", alpha=1.0) +
scale_x_continuous(breaks = scales::pretty_breaks(n = 10))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment