Created
April 6, 2020 08:29
-
-
Save thomas-neitmann/d71a0898fc9e6f3467c600058670884c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(ggcharts) | |
library(dplyr) | |
dreaded_lang <- tibble::tribble( | |
~language, ~pct, | |
"VBA", 75.2, | |
"Objective-C", 68.7, | |
"Assembly", 64.4, | |
"C", 57.5, | |
"PHP", 54.2, | |
"Erlang", 52.6, | |
"Ruby", 49.7, | |
"R", 48.3, | |
"C++", 48.0, | |
"Java", 46.6 | |
) | |
dreaded_lang$label <- sprintf("%1.1f%%", dreaded_lang$pct) | |
bar_chart(dreaded_lang, language, pct, highlight = "R", bar_color = "black") + | |
geom_text(aes(label = label, hjust = -0.1), size = 5) + | |
scale_y_continuous( | |
limits = c(0, 100), | |
expand = expansion() | |
) + | |
labs( | |
x = NULL, | |
y = "Developers Who are Developing with the Language but<br>Have not Expressed Interest in Continuing to Do so", | |
title = "Top 10 Most Dreaded Programming Languages", | |
subtitle = "*R Placed 8th*", | |
caption = "Source: Stackoverflow Developer Survey 2019" | |
) + | |
mdthemes::md_theme_classic(base_size = 16) + | |
theme( | |
axis.text.x = element_blank(), | |
axis.line.x = element_blank(), | |
axis.ticks.x = element_blank() | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment