Skip to content

Instantly share code, notes, and snippets.

@mschnetzer
Created April 3, 2018 08:10
Show Gist options
  • Save mschnetzer/9061d4c0aaed0b326af6076f95082231 to your computer and use it in GitHub Desktop.
Save mschnetzer/9061d4c0aaed0b326af6076f95082231 to your computer and use it in GitHub Desktop.
Vergleich Einkommens-Gini Deutschland und Österreich
library(tidyverse)
library(eurostat)
library(ggthemes)
eurostat <- get_eurostat("ilc_di12",filters=list(geo=c("AT","DE")),type="code",time_format="num")
eurostat$time <- as.factor(eurostat$time)
eurostat %>% filter(time %in% 2005:2016) %>%
ggplot(aes(x=time,y=values,group=geo,colour=factor(geo,labels=c("Österreich","Deutschland")))) +
geom_line(size=1.2) + geom_point(size=1.2) + xlab(" ") +
ylab("Gini-Koeffizient") + labs(color = " ") + theme_fivethirtyeight() +
ggsave("ginideat.pdf")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment