Google Ads


Site Stats

Daves Redistricting 2.1 - 2010 Data [Updated 2]

by: dgb

Thu Feb 17, 2011 at 10:45 AM EST


2010 data is here! Yesterday evening I uploaded Daves Redistricting 2.1. Here's what is new:

2010 data is available for VA, MD and NJ. More states will be available in the next 2 days.
[Update: LA, MS and IN available]

[Bugs fixed in 2.1.1:
- old election data shows up
- 0% Obama districts corrected (to make them 0% McCain, too)
- unassigning districts now ok (lesson: don't divide by zero!)]

Election data along with the 2010 data is available for VA and MD.

The UI is improved.

Z-Drag (like Ctrl-Drag) allows you to draw a box to color. Works on both Mac and Windows.

In other news, I will potentially be partnering with a non-profit and seeking contributions to support the Dave's Redistricting project. I will let you know when I have more news on that.

More detail below.

dgb :: Daves Redistricting 2.1 - 2010 Data [Updated 2]
1) The data: When you select a state you will be asked to select a data set from the choices available.
  -- I've downloaded all the data for available states and the vote district (VTD) shapes from the Census site. I expect to have MS, LA, AR and IN late today. I'm currently using VTDs. I will evaluate using Block Groups in states where VTDs are too big.
  -- 2010 data includes voting age population (18+) which is now shown with the overall population data.

2) Election data: a group of professors, led by Steve Ansolabehere of Harvard, is gathering election data for nearly all states. In general you will see the 2008 Pres numbers + an Average over some elections in the last decade. Important:
  -- To aggregate the Average across VTDs, we use the voting age population for the VTDs.
  -- To aggregate the 2008 Pres, we (temporarily) do the same. Steve is working to get VTD actual Pres vote counts in the data and I will use them when available.

3) The UI: Top Panel
  -- you can minimize the top panel.
  -- Tools and Area Views are collapsed by default. Tools includes less used stuff like Auto Color, Reposition CD Labels and more. Also, a check box to go back to the "Old" coloring method.
  -- Help button takes you to a dialog where you can navigate to "How To" sections on common tasks. The link to the Help Page is on those dialogs.

4) The UI: Right Panel
  -- The data for the current CD has been moved from the bar under the top panel to the right panel. This should give you much better readability, especially with more data.
  -- You'll notice also that VTD tool tips appear in the upper right of the map, also for better readability with more data. Note: I use the less desirable fixed-width font for performance reasons.

5) UI: Coloring:
  -- "New" coloring (introduced 1 months ago) is on by default. "Old" is still available. See Tools.
  -- Z-Drag, like Ctrl-Drag, drags out a box and colors the box. Ctrl-Drag was introduced 1 month ago, but does not work on the Mac. Z-Drag does the same thing and works on both Mac and Windows. [Hold down the Z key, hold down mouse button and move the mouse to draw a box. When you release, everything in the box is colored. On the Mac TrackPad, moving 3 fingers is the same as pushing the pad down while moving.

6) Show:
  -- City/Town boundaries: These are a prominent magenta. They are meant to help you color in or out of the boundaries, rather than for pretty viewing.
  -- Vote District lines: when you hide these the app zooms out and back in. I have found no other way to get them to go away. (I've tried a lot of other things.)
  -- County lines are a little thicker.

7) Performance:
  -- Bottom line: this takes a bunch of memory no matter what.
  -- The DataGrid used to show CD data on the right panel is fairly expensive, which is why I didn't use it for VTD tool tips.
  -- Setting the tool tips has always been slow. When loading a saved DRF, I use to do them twice. That's been fixed, but loading a large state is still slow. I intend in the future to push this to the background.
  -- Silverlight 4 seems to have some memory leaks. There's much discussion on their forums. My app may force you to upgrade to 4.0.6something, but not all is perfect.
  -- Because of memory issues, I recommend refreshing your browser if you are switching a lot between states. I found that, using the 2010 data, if I did VA, then NJ, and both again, I would run out of memory. (Browser would should memory usage of 1.3GB.)

8) The Help pages are not updated yet. I'll be working on that soon.

Thanks for your feedback. As always, let me know of bugs. Happy Redistricting!

Tags: , , (All Tags)
Print Friendly View Send As Email

FYI, Maryland's partisan data is screwed up
It gives crazy negative numbers for one candidate in most of the precincts.

Still?
That was true for Maryland last night for a hour or two, but I fixed about 8:30pm PST. I'm showing it working this morning.

[ Parent ]
I got it
I had to clean out all the Maryland data from the Silverlight folder.

[ Parent ]
A mini-thread on the new app came up in yesterday's open thread
Starting with andgarden's comment here, where he mentions "There are some bugs though (i.e., you can't shade the map by political data, and it seems like if you delete a whole district, its political percentages won't show up if you redraw it)." I've experienced both of these issues. Reloading the map solves the second one.

The only other bug report in that thread right now is M Riles saying "It seems a few precincts in Loudoun have no votes for Obama, which results in the App showing that McCain won the county.  Otherwise, everything seems great." I didn't look to confirm myself.

30, male, MI-11 (previously VA-08). Evangelical, postconservative, green.


Bug in the data
Thanks for pointing out the Loudoun County problem. Looking at the data, I see 15 districts with non-zero population and 0% for Obama. I'll check with Steve on that.

[ Parent ]
Central Voting Precinct in Arlington County
Is another precinct with no votes for Obama and over 4k for McCain.  It seems like this might be a more widespread problem.  Thanks for all of your work!

26, Male, Democrat, VA-08

[ Parent ]
Another one
South County Voting District in Fairfax County has no Obama votes

Male, VA-08

[ Parent ]
Precinct was created after 2008...
...but there are Creigh numbers for it:  41% to McDonnell's 59%

[ Parent ]
That's a new precinct.
Some in Loudoun are like that.  I think the population is correct but no political data.

[ Parent ]
I stand corrected...
That's not new, but the other "empty" ones in NOVA are.

[ Parent ]
This sounds plausible
I'm checking with the prof on these and he's looking into it. Since VA had an election in 2009, one might see "avg" data but not 2008 data. If this is the case, then I'll correct the app to give 0 votes to both sides.

The way the prof's team has put together the data is to give the Avg Dem % over 2000-2009 (or whatever period; MD is different; and I'm trying to find out exactly what offices are in the avg) and the Dem % for Pres 2008. They have not (yet) provided the actuals for Pres 2008, so I'm using the voting age population (as explained in the diary). If I get get the actuals (even vote total for the precinct) then that solves the problem, because the total will be 0 for precincts new in 2009.


[ Parent ]
Also, I should have mentioned
some of the positives. App performance seemed faster to me last night when I tested out Virginia. The Bing map, in particular, seemed to be adjusting to pans and zooms more quickly. I really like the new thicker county lines. I also really appreciate having locality lines again. And the new ability to turn off all of the different sorts of lines is really nice from a posting-pictures-to-diaries perspective.

30, male, MI-11 (previously VA-08). Evangelical, postconservative, green.

Thanks so much for your hard work on this, Dave
I really appreciate a lot of this, it all looks great. I've been waiting for Virginia for so long. I would second the problem some others have mentioned where many precincts in Loudoun County (Virginia) show no votes for Obama so it appears that McCain won the county when in fact Obama won it.

Male, VA-08

sounds good
I'll try it out this evening and redo my VA and MD maps. Dave is the man.

41, Ind, CA-05

It'll work for me one day, in Linux
I actually see a map this time... but the data has been "loading" for Oregon for an hour and a half now, without progress.

I'm almost certain it's related to Moonlight (the open source implementation of Silverlight), and its interaction with Firefox on 64-bit systems, based on issues similar to what's happening with Flash on Linux 64-bit browsers. (my laptop has 8GB of RAM, and less than 4 is currently in use, so that shouldn't be an issue).


It does work on Win/FF
I just tried on Win7 with Firefox, to make sure. It loads fine. Do other states work with Moonlight? I'm now using Silverlight 4, as I'm sure you know, but it may work with something matching 3. Good luck.

[ Parent ]
I've tried to use Moonlight (on Linux/FF) with zero success
I assumed that this was a limitation in Moonlight though, which I don't believe implements all of the silverlight functionality.  While I would love it to work on Linux, simply because my Linux box has much more memory than my windows laptop, I wouldn't make it a high priority, since working around Moonlight's limitations is probably more trouble than it's worth.

28, Unenrolled, MA-08

[ Parent ]
Just tried several other states
Seems to get stuck at the same level, approx 10% of the length of the load bar.

The only thing I use Windows for now is to do my taxes. If you know Linux users, you'll realize that it's the functional equivalent of a religious objection.


[ Parent ]
Will We Be Getting 2010 Election Data in There At All?


20 M MD-01

Yes
I think the profs will have election data for almost all states. When they have it ready I will include it as soon as I can.

[ Parent ]
Very cool upgrade
You could almost use this to draw a real map in Virginia. Thanks Dave.

I look forward to helping to sort out bugs. . .


Thanks
You all are great at finding those bugs. Like the Loudoun County data. I would never have found that.

[ Parent ]
Great work. Quick question...
What are the races involved in Virginia's "avg. Dem performance 2000-20009"?

Good question
I have to ask the prof, Steve, for more specifics. This is what he has indicated for VA.

[ Parent ]
questions
Dave, Forgive me if what API/Mapserver are you using on the back end? Also have you thought about doing big states like California & Texas as stand alone pages to help with memory issues?
Hank

Bing Maps
The framework is Silverlight and there's a Bing Map control that you can add to a Silverlight app.

I'll put some more thought into CA and TX. CA especially worries me. Thanks.


[ Parent ]
TX
Speaking of TX, when do you think you'll have the 2010 data implanted?

21, Conservative Gay Democrat, NM-2 (Childhood) TX-10 (Home) TX-23 (School);   DKos: wwmiv.

[ Parent ]
...
Well! That week has come and passed. Enjoying your vacation?

21, Conservative Gay Democrat, NM-2 (Childhood) TX-10 (Home) TX-23 (School);   DKos: wwmiv.

[ Parent ]
Yes
The 28th would be a week. Good chance I'll have it then.

[ Parent ]
Awesome!
I look forward to it.  

By the way, I think you should win some sort of citizens in government award for this.


[ Parent ]
Obama-McCain percentages
How do you guys assign these? Is there a way to do it automatically, or do you have to do it yourself?  

"I have never deliberately given anybody hell. I just tell the truth on the opposition-and they think it's hell."--President Harry Truman. President Obama, are you listening?

Aggregate like this
As I described in a comment above, the data I have from the professors gives the Dem % (both an avg and for the Pres election). I use the voting age population (VAP) when aggregating precincts (grouping them into a CD and giving you the number for the CD). I'm trying to see if they can provide the actuals #votes for the Pres election, because that is precise. For the Avg, they don't have actuals for every election in the avg. It seems there's a debate going on as to what to use to aggregate the average. In any case, I'm using the VAP.

[ Parent ]
New Jersey
I updated my New Jersey diary with racial data. All of my districts' populations are what I thought they would be, which is good news. My districts have more minorities than I thought. Without trying to create more than 2 minority-majority districts, I created 3, and almost a 4th.

26, male, Dem, NJ-12

Thanks so much!
 I noticed loading the app was slow for me at first but panning as others have said moves pretty quickly.  

for more election analysis, visit  http://frogandturtle.blogspot....




17, CA-06,  


Also
 Are you planning to let users be able to draw a whole county just by clicking on it instead of looking around it through all the precincts? Also, I have thought the Assign Old CDs is a bit slow.

Overall though, I am really happy you got the census data and the partisan data! Thanks and keep up the good work!

for more election analysis, visit  http://frogandturtle.blogspot....




17, CA-06,  


Not really
I put in the Ctrl-Drag and Z-Drag, so you can cover a large rectangular area easily. I had hoped that that would meet the "color a county" need, although I know that most counties are not rectangles. There's too much to do for me to get to that soon anyway. Ping me again in a month or so and let me know if you feel it's really needed. Thanks.

[ Parent ]
I did not notice that
 Sorry about that

for more election analysis, visit  http://frogandturtle.blogspot....




17, CA-06,  


[ Parent ]
election results problem
Ever since the switch I can't get the total New York Election results for a whole district?

Texas
has the same problem.

[ Parent ]
That was the case
For Maryland last night, but it was fixed today. I assume it's a simple bug Dave can fix.

20, CD MA-03/NH-01/MA-08

[ Parent ]
Doh!
Easy fix. Probably tomorrow. Thanks for tracking these down!

[ Parent ]
Hey Dave
Any chance of getting the partisan shading back? It's really useful!  

[ Parent ]
Yes.
Another easy fix.  

[ Parent ]
also
many virginia vote counts are off. i don't think negative a million ppl voted for obama in the panhandle, although it could have happened.

sometimes i just need to switch which district number i use and it works again, but it seems completely random.

help me out?

18, Dem, CA-14 (home) CA-09 (college, next year). social libertarian, economic liberal, fiscal conservative.   Everybody should put age and CD here. :)


[ Parent ]
Saving and reloading
will clear out the bug. My experience so far (and I think I read andgarden concurring) is that it happens when you start on a district, unassign all of its precincts, and then try using it again.

30, male, MI-11 (previously VA-08). Evangelical, postconservative, green.

[ Parent ]
hey Dave
Thanks again for all the work you've put into this - I just have 2 comments:

1) Aside from all the problems everyone else has encountered, I have been having issues with the statistics box being too small - I have to scroll over to see numbers, and when I go to scroll the box gets all jumpy and tries to resize but can't. I'm using Firefox on a Macbook.

2) You'll have to make one last edit to MD's data when possible. Right now, the state is retabulating the census data in order to split up the prisons and place the prisoners at their last known address, as per a new state law. Once they come out with the data, you'll have to make that final adjustment, and then we'll have the same data the state will use to redistrict.

21, Male, Democrat, MD-02 (home/registered), MD-05 (college)


I'll look at it
I have a few other bugs to fix today, but I will at least investigate on the Mac. What size Macbook do you have?

And thanks for the tip on MD. I will pass to the profs to make sure they are aware as well.

Thanks.


[ Parent ]
13 inch


21, Male, Democrat, MD-02 (home/registered), MD-05 (college)

[ Parent ]
Safari is good
I don't have FF on my MacBook (also 13 inch). Safari seems to work fine. I can see that when I shortened up the Safari window the vertical scroll bar appears (with Maryland), but it seems I can shrink more and less fast and it responds reasonably. My code does respond to resize by resizing the map and left panel to match, so maybe FF is feeding a bunch of changes that are getting backed up. Not sure. I won't really be able to look more today (and I'm away next week). Let me know if Safari is better. Thanks.

Re: election data: it does look strange. I think aggregating using eligible voters skews it some, but 64% seems really high. (What were the MD numbers for Obama?) Anyway, we'll work on that.


[ Parent ]
I'll check Safari
As for Obama numbers, he got 61.9% in the state as a whole, although this would go down some if absentees are excluded.

It looks to me like you assigned all third-party candidate votes to Obama for some reason, since the totals add to 100% for just Obama and McCain, and you don't have a third party category. I think you might just have to put in all the actual numbers by hand instead of regressing.

21, Male, Democrat, MD-02 (home/registered), MD-05 (college)


[ Parent ]
The data
Yeah. The profs have only provided the 2-party Dem % for the Pres and the Avg. Not what I would choose. I'm waiting for them to get back on providing vote counts for the Pres election at least.

Thanks.


[ Parent ]
Partisan Data for MD and VA seems odd
In both states, the total number of votes in 2008 when you view the data statewide is exactly double to what it should be.

Additionally, after using the CTRL-Drag, the partisan data for the district used will switch to the negative millions. However, if I simply sweep to fill the districts, this does not happen. Has anyone noticed this?

GOP, MA-5


I know
I'm working with the professor who is providing the data. The problem is the data currently only has the Democratic % in each precinct, not the votes. So I'm using the voting age population to show and aggregate. I'm adding a tooltip message to that effect. Also, I'm trying to get the vote counts for the Pres election. (For the average, there's not a single vote count.)

I should probably simply remove showing vote counts that are wrong, eh?

The second thing is definitely a bug. Other comments ran into something similar that I'm looking into now.

Thanks.


[ Parent ]
yeah
The other thing is, I noticed the Dem percentages are wrong in some areas based on what I've seen before. For some reason, Obama's numbers are overstated nearly everywhere. Check the precinct in Baltimore County in northern Dundalk - it says Obama got 55.3% when I know it was something like 51-52% before (and this is even after I adjusted the data on my own to add in absentee votes).

Also, there's one precinct in Bowleys Quarters in SE Baltimore County that doesn't show any votes for Obama. And there are a few in Northern PG that don't show any population but have Obama numbers.

21, Male, Democrat, MD-02 (home/registered), MD-05 (college)


[ Parent ]
I should add
That as an aggregate the state shows 64% for Obama, which is way too high.

21, Male, Democrat, MD-02 (home/registered), MD-05 (college)

[ Parent ]
No, Thank You Dave
I still can't get over how awesome this app is. Thanks!

GOP, MA-5

[ Parent ]
Bugs fixed
See the update above for description.

Hello Dave
For VA, even though the new voting districts now show 0 votes for McCain and Obama when I mouse over them, they're still lowering Pres. Obama's average the in the right sidebar the same as they were before.

26, Male, Democrat, VA-08

[ Parent ]
Thanks for the bug update
I guess this is a feature request, but I wonder if you might make it possible to toggle the shading so we can see the election averages on the map?


Thanks again Dave
I for one love your app and will try out the Virginia map once I have some free time.

Question- is the partisan data available under App 1.0? I couldn't find it. I don't like to use the new version because of the panning and the auto-shading. Plus I'm a Republican and hate change.


No
I haven't touched 1.0 in months. So it will have nothing new. Don't know what you mean by auto-shading. You can select the Blank map in 2.0/2.1, so it looks like 1.0 color-wise. Have fun.

[ Parent ]
When I open the app
And click on a state to load its data, the data will not load. There is no progress bar or anything.  

for more election analysis, visit  http://frogandturtle.blogspot....




17, CA-06,  


I'm suddenly seeing the same problem
Using Safari in 10.6.6.

[ Parent ]
It's
 Working well now.  

for more election analysis, visit  http://frogandturtle.blogspot....




17, CA-06,  


[ Parent ]
Someone emailed me
I got an email this morning, before taking off on vacation. It seems that the web service stopped working. 1.0 was not working 2.0, 2.1 -- nothing. They all use the same service (program on the server to serve up the data). Weirdest thing since I had not changed that for 4 or 5 days. So I re-copied the service file and it worked. I'm sure glad, since it was mysterious; I had never seen this before on this host.

[ Parent ]
if i do
california with 2000 voting districts, then use new pop estimates, silverlight keeps crashing. i'm in firefox, and this has never happened before, but it has 4 times in a row now

18, Dem, CA-14 (home) CA-09 (college, next year). social libertarian, economic liberal, fiscal conservative.   Everybody should put age and CD here. :)

obama mccain election
can you put back the total number of votes for Obama and McCain instead of only the %

When I get actual numbers from the profs
The vote counts were not actual vote counts, but eligible voters. I'm still waiting for the data that will include actual counts (or turnout).

[ Parent ]

Copyright 2003-2010 Swing State Project LLC

Primary Sponsor

You're not running for second place. Is your website? See why Campaign Engine is ranked #1 in software and support among Progressive-only Internet firms. http://www.mediamezcla.com/

Menu

Make a New Account

Username:

Password:



Forget your username or password?


About the Site

SSP Resources

Blogroll

Powered by: SoapBlox