Created
September 20, 2018 10:37
-
-
Save mschnetzer/86a94ca0deaeb1554ba25a986cd535e7 to your computer and use it in GitHub Desktop.
Scientists and engineers per 1,000 pop
This file contains hidden or 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(tidyverse) | |
library(eurostat) | |
sci <- get_eurostat("hrst_st_nocc",filters=list(geo=eu_countries$code,unit="THS",isco08="TOTAL",category="SE",age="Y25-64",lastTimePeriod=1),type="code",time_format = "num") %>% | |
select(geo,values) %>% rename(sci=values) | |
pop <- get_eurostat("demo_gind",filters=list(geo=eu_countries$code,indic_de="JAN",lastTimePeriod=1),type="code",time_format = "num") %>% | |
select(geo,values) %>% rename(pop=values) | |
# Scientists are measures in Thousands | |
data <- left_join(sci,pop,by="geo") %>% mutate(scipop = round(sci*1000/pop*1000,0)) %>% | |
arrange(desc(scipop)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment