The other day Ezra Klein tweeted this:
And if you followed that link, you would see charts that looked like this:
And I thought, “cool.” It’s a really appealing way to illustrate cross tabs data from polling. (I didn’t read much about the report that is linked, just enough to know that it has something to do with opinions about whether to invade Iran or something. For the record, I’m against invading Iran.)
Then, because I’m a programmer and a nerd, I decided to write my own program to produce cool charts like that. So I wrote this little MFC-based app:
You can enter all your polling data into the form and it draws the graph in real-time, updating as you change values. It’s neat. You can also save and load the data you’ve entered, and it saves to a simple text file so you can edit the data by hand if you want. It also exports the generated chart to a PNG file for uploading to the intertubes. (Every instance of “you can” in the preceding sentences should read “I can.” You can’t for two reasons: you probably have no desire to. And I haven’t decided whether to upload an executable yet.)
Now there’s probably a simple Excel spreadsheet plugin or some nonsense that does this and has way more features and prettier colors than mine. I just thought it looked like a cool problem to solve, so I wrote it myself. For those wondering, the secret is a sine wave from negative pi/2 to pi/2, halved. That’s all I’m saying.
Anyway, this post is just about the actual app. You can see the chart I was making up there, and I’ll be making some more in regards to last night’s South Carolina primary, and what I think some of these numbers might mean.