Several months ago, I started a really simple project to compute Congressional apportionment, using the method defined in current law, with the intent of considering several different scenarios. I haven’t really had time to work on this since then, but at least I finally got around to actually posting about it.
You can get the code from my Github repository. It consists of a small Ruby library, apportionment.rb, that encapsulates both the current and previous algorithms (assuming I implemented them correctly) and, as test data, the results of the 2010 Census and subsequent House of Representatives apportionment. There are some convenience routines for comparing a computed apportionment against an already-known one (i.e., the current state of the House. There’s also a test harness, test-apportionment, which both demonstrates that I correctly calculate the post-2010 apportionment, and can also be modified to calculate other scenarios.
As an example, I modified test-apportionment to use the 2014 U.S. Census Bureau state population estimates rather than the 2010 inaccurate-but-the-Supreme-Court-doesn’t-understand-statistics official counts:
$ ./2014_apportionment Minnesota loses 1 seats (was 8, now 7) North Carolina gains 1 seats (was 13, now 14) Pennsylvania loses 1 seats (was 18, now 17) Texas gains 1 seats (was 36, now 37)
(Sorry, I didn’t bother to implement English noun morphology.) Another example script, at_large_states, answers the question I originally implemented the library to understand: How big would the House of Representatives have to be in order for the states that are currently represented by a single at-large member to get an additional set? I won’t keep you in suspense:
$ ./at_large_states 615 required to give Alaska a second seat 483 required to give Delaware a second seat 441 required to give Montana a second seat 613 required to give North Dakota a second seat 529 required to give South Dakota a second seat 721 required to give Vermont a second seat 773 required to give Wyoming a second seat
This is done completely brute-force-style, which might not be the best way, but is fast enough on my workstation anyway. There are pretty good arguments for increasing the size of the House — which hasn’t changed since the Depression, except temporarily after the admission of Alaska and Hawaii, while the population of the country has more than doubled — and it’s a simple matter to compute what would happen in that case (by modifying the test harness):
$ ./491_seat_house Alabama gains 1 seats (was 7, now 8) Arizona gains 1 seats (was 9, now 10) Arkansas gains 1 seats (was 4, now 5) California gains 6 seats (was 53, now 59) Colorado gains 1 seats (was 7, now 8) Connecticut gains 1 seats (was 5, now 6) Delaware gains 1 seats (was 1, now 2) Florida gains 3 seats (was 27, now 30) Georgia gains 2 seats (was 14, now 16) Idaho gains 1 seats (was 2, now 3) Illinois gains 2 seats (was 18, now 20) Indiana gains 1 seats (was 9, now 10) Iowa gains 1 seats (was 4, now 5) Kansas gains 1 seats (was 4, now 5) Kentucky gains 1 seats (was 6, now 7) Louisiana gains 1 seats (was 6, now 7) Maryland gains 1 seats (was 8, now 9) Massachusetts gains 1 seats (was 9, now 10) Michigan gains 2 seats (was 14, now 16) Mississippi gains 1 seats (was 4, now 5) Missouri gains 2 seats (was 8, now 10) Montana gains 1 seats (was 1, now 2) New Jersey gains 2 seats (was 12, now 14) New York gains 4 seats (was 27, now 31) North Carolina gains 2 seats (was 13, now 15) Ohio gains 2 seats (was 16, now 18) Oklahoma gains 1 seats (was 5, now 6) Oregon gains 1 seats (was 5, now 6) Pennsylvania gains 2 seats (was 18, now 20) Tennessee gains 1 seats (was 9, now 10) Texas gains 4 seats (was 36, now 40) Virginia gains 2 seats (was 11, now 13) Washington gains 1 seats (was 10, now 11) Wisconsin gains 1 seats (was 8, now 9)
One of the thoughts I had was that it would be interesting to see if any of these scenarios reflected a particular red or blue advantage in the Electoral College, but never got around to implementing that. Two scenarios I did look at were Puerto Rico statehood (they’d get five seats) and giving the District of Columbia an actual voting House seat (if D.C. were a state, it would only be entitled to one anyway — retrocession might actually be a better deal for the District’s residents for a variety of reasons). When a new state is admitted, for the past century and change Congress has increased the size of the House only temporarily, until the next decennial census, so you might want to ask questions like “What if Puerto Rico had been admitted in 2009?” That’s actually not a question we can answer accurately, because it’s too counterfactual: the Census Bureau doesn’t do the “actual enumeration” business in nonvoting territories so we don’t know what the official-for-apportionment-purposes population of the island would have been in 2010. But we can at least get an idea of how 2011 might have turned out, with the caveat that I’m using the 2014 estimated population here:
$ ./pr_in_2009 California loses 1 seats (was 53, now 52) Florida loses 1 seats (was 27, now 26) Minnesota loses 1 seats (was 8, now 7) Puerto Rico was not represented in Congress for Census 2010, now has 5 seats Texas loses 1 seats (was 36, now 35) Washington loses 1 seats (was 10, now 9)
It’s not clear to me if either party would have benefited in the 2012 general election as a result of this (and I don’t know what PR politics would look like in a statehood situation anyway).
One final thing you can do is switch out the apportionment algorithm. I have attempted to implement “Fair Share” a/k/a “Hamilton’s Method” in the library, but since this method hasn’t been used in more than a century I have no easy way of validating that its results are correct — for Census 2010 my implementation generates the same apportionment for both methods.
Anyway, if you’re interested in this sort of thing, grab the code and have fun. If you come up with anything interesting, or especially a usable visualization (something I’m no good at), please let me know (or submit a pull request)!