zmeers / ggparliament

Simple parliament plots using ggplot2
https://zmeers.github.io/ggparliament/
Other
150 stars 13 forks source link

Unknown or uninitialised column: 'party'. #19

Closed RobWHickman closed 6 years ago

RobWHickman commented 6 years ago

parliament_data giving this error. Everything seems to be working so I assume its a case of just going through the code and removing this. Will leave it for the immediate future as it isn't breaking anything

zmeers commented 6 years ago

It looks like we don't even need the party variable. Party_short and party_long expand when the aggregated party seats are unravelled to their length when we use tidyr::uncount(). Moreover, it also looks like we don't need party_names in parliament_data, either. We might as well shorten the function where possible, IMO.