Another look at ideology of the US congress
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.
In response to last week's post on the rapidly increasing ideology of the US Republican Party, Mike Lawrence suggested another way of looking at the DW-NOMINATE ideology data. Rather than simply looking at boxplots of the congress scores by party over time, we could fit a smooth curve to get a better sense of the trends over time. Mike provided R code to do exactly that, using a generalized additive model to fit the smooth curve to the data since the two-party system began, and using his ez package to visualize the result. I modified Mike's code slightly to match the traditional party colours and to put year (rather than congress number) on the horizontal axis:
In this chart, higher means more rightward-leaning. While the Democratic party has drifted leftwards over the past 50 years, you can see a sudden turn to the right beginning in 2005. And in this version of the chart you can clearly see the march of the Republican party to the far right, beginning in 1975.
R-bloggers.com offers daily e-mail updates about R news and tutorials about learning R and many other topics. Click here if you're looking to post or find an R/data-science job.
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.