Wednesday, July 09, 2008

We're moving to procrastiblog.com

I'm moving the blog to a new URL and a new host.* Future posts will appear at



The new feed is http://procrastiblog.com/feed/. The existing archives have been imported to the new site.

* One thing shouldn't require the other but—despite some dedicated users on the forums (or actually, just this one guy)—Blogger showed a perfect indifference to getting procrastiblog.com up on their servers. I'll give WordPress a chance to squander my money for a while.

Sunday, June 29, 2008

OCaml's Unix module and ARGV

Be warned: the string array argument to Unix.create_process et al. represents the entire argument vector: the first element should be the command name. I didn't expect this, since there is a separate prog argument to create_process, and ended up with weird behavior* like,


# open Unix;;
# create_process "sleep" [|"10"|] stdin stdout stderr;;
10: missing operand
Try `10 --help' for more information.
- : int = 22513

This can be a bit insidious—in many cases skipping the first argument will only subtly change the behavior of the child process.

Note that the prog argument is what matters in terms of invoking the sub-process---the first element of the argument vector is what just what is passed into the process. Hence,

# create_process "gcc" [|"foo";"--version"|] stdin stdout stderr;;
- : int = 24364
foo (GCC) 4.2.3 (Ubuntu 4.2.3-2ubuntu7)


* Actually, this "weird behavior" is the test that finally made me realize what was going on. The emergent behavior of my app was much more mysterious...

Tuesday, June 24, 2008

Resetting a Terminal

You tried to cat a binary file and now your terminal displays nothing but gibberish? Just type reset (it may look like ⎼␊⎽␊├).

It has taken me more than 10 years to learn this.

[UPDATE] Interestingly, this doesn't work in my (alas, ancient) Mac OS X 10.3.9 terminal. Any tips? Also, why did curl URL_TO_BINARY hose my terminal in the first place?

Monday, June 23, 2008

Ripping a Muxtape

So Muxtape is a pretty cool site, but a little frustrating. If a friend posts a really cool mixtape (maybe you know somebody who just barely entered the Aughties), it would be nice to be able to download it and save it, just like all those old cassette mixtapes sentimentally rotting underneath your bed.

Enter muxrip. This simple Ruby script takes the name of the mixtape, downloads it, and creates a playlist for you in M3U or iTunes format. (Acknowledgments: the script basically just adds some polish to this previous effort.)

PLEASE: Use this script responsibly. It would be a shame for Muxtape to get shut down.

ALSO: I wouldn't be surprised if this suddenly stopped working. It depends on elements of the page layout and URL scheme that might (almost certainly will) change without notice.

Saturday, June 21, 2008

An Open Letter to eMusic

I regret to inform you I am canceling my eMusic subscription,
effective immediately. Although I admire the fact that you have
provided DRM-free music downloads since the pre-Napster era and try my
best to support small, independent businesses, my dissatisfaction with
your service has been too great for too long and the convenience and
selection offered by your competitors (e.g., Amazon's MP3 store) is
too good to pass up. It pains me to see big players like Amazon and
Apple push companies like eMusic out of business, but if you are to
survive, you will have to be more innovative and customer-focused than
you have been in the time that I have subscribed. I hope that you will
re-think your business model, increase the value of your product, and
win me back as a customer in the future.

In that spirit, I want to offer some specific advice about how your
service could improve.

- Your site provides almost no information about what albums will be
available when. So far as I can tell, the only information provided
is a small "Coming Soon" box with no more than 8 artists---often
just the names of the artists without release dates---in the bottom
corner of the "New on eMusic" page. Albums that have been released
and are available for download elsewhere are not acknowledged on
the artist page, not even to say "this album will be available
soon." For example, Sloan's "Parallel Play" has been available on
Amazon since June 10. As of June 21, I can find no information on
your site about whether this album will ever be available, even
though you offer all of Sloan's previous albums on the same label.

- If I want to download an album with more tracks than I have in my
monthly subscription, a pop-up asks me if I want to upgrade my
subscription (i.e., to permanently increase my monthly fee and
download allotment). Although there are "Booster Packs" allowing
the one-time download of 10 or 20 tracks, this option is not
presented in the pop-up, nor in the page presented when one clicks
on "More Options"---only a savvy and determined user will find
them. The Booster Packs should not only be made easily available at
this point, there should be an additional option that you do not
provide: to download as many tracks as I have available within my
subscription and queue up the remaining tracks for download when my
account refreshes. This doesn't have to be the first option
presented---I understand the desire to nudge your users towards
more spending more money on the site---but it should be available
(and one should not cross the line from nudging your customers to
misleading them and ripping them off).

These two points may seem inconsequential, but they have been a
constant source of annoyance for me. It is small matters like these
that build a customer relationship that survives a spotty selection
and waiting for the latest indie hits.

Best regards,
Chris

Thursday, June 19, 2008

Sunday, June 08, 2008

Tweaking an RSS Feed in Python

I've been teaching myself a bit of Python by the just-in-time learning method: start programming, wait for the interpreter to complain, and go check the reference manual; keep the API docs on your hard disk and sift through them when you need a probably-existing function. Recently, I wanted to write a very simple script to manipulate some XML (see below) and I was surprised (though it has been noted before) at the relatively confused state of the art in Python and XML.

First of all, the Python XML API documentation is more or less "go read the W3C standards." Which is fine, but... make the easy stuff easy, people.

Secondly, the supposedly-standard PyXML library has been deprecated in some form or fashion such that some of the examples from the tutorial I was working with have stopped working (in particular, the xml.dom.ext module has gone somewhere. Where, I do not know).

So, in the interest of producing more and better code samples for future lazy programmers, here's how I managed to solve my little problem.

The Problem: Twitter's RSS feeds don't provide clickable links

The Solution: A script suitable for use as a "conversion filter" in Liferea (and maybe other feed readers too, who knows?). The script should:


  1. Read and parse an RSS/Atom feed from the standard input.

  2. Grab the text from the feed items and "linkify" them

  3. Print the modified feed on the standard output.


Easy, right? Well, yeah. The only tricky bit was using the right namespace references for the Atom feed, but again that's only because I refuse to read and comprehend the W3C specs for something so insignificant. I ended up using the lxml library, because it worked. (The script would be about 50% shorter if I hadn't added a command-line option --strip-user to strip the username from the beginning of items in a single-user feed and a third shorter than that if it only handled RSS or Atom and not both.)

Here's the code, in toto. (You can download it here.)

#! /usr/bin/env python

from sys import stdin, stdout
from lxml import etree
from re import sub
from optparse import OptionParser

doc = etree.parse(stdin)

def addlinks(path,namespaces=None):
for node in doc.xpath(path,namespaces=namespaces):
# Turn URLs into HREFs
node.text = sub("((https?|s?ftp|ssh)\:\/\/[^\"\s\<\>]*[^.,;'\">\:\s\<\>\)\]\!])",
"<a href=\"\\1\">\\1</a>",
node.text)
# Turn @ refs into links to the user page
node.text = sub("\B@([_a-z0-9]+)",
"@<a href=\"http://twitter.com/\\1\">\\1</a>",
node.text)

def stripuser(path,namespaces=None):
for node in doc.xpath(path,namespaces=namespaces):
node.text = sub("^[A-Za-z0-9_]+:\s*","",node.text)

parser = OptionParser(usage = "%prog [options] SITE")
parser.add_option("-s", "--strip-username",
action="store_true",
dest="strip_username",
default=False,
help="Strip the username from item title and description")
(opts,args) = parser.parse_args()

# For RSS feeds
addlinks("//rss/channel/item/description")
# For Atom feeds
addlinks( "//n:feed/n:entry/n:content",
{'n': 'http://www.w3.org/2005/Atom'} )

if opts.strip_username:
# RSS title/description
stripuser( "//rss/channel/item/title" )
stripuser( "//rss/channel/item/description" )
# Atom title/description
stripuser( "//n:feed/n:entry/n:title",
namespaces = {'n': 'http://www.w3.org/2005/Atom'} )
stripuser( "//n:feed/n:entry/n:content",
namespaces = {'n': 'http://www.w3.org/2005/Atom'} )

doc.write(stdout)


If there are any Python programmers in the audience and I'm doing something stupid or terribly non-idiomatic, I'd be glad to know.

Thanks in part to Alan H whose Yahoo Pipe was almost good enough (it doesn't handle authenticated feeds, as far as I can tell) and from whom I ripped off the regular expressions.

[UPDATE] Script changed per first commenter.

Top Chef and BSG Catch-Up

I have been remiss in blogging Top Chef and Battlestar Galactica this year. Suffice it to say I'm watching and enjoying, but my ardor for both has somewhat dimmed.

Unlike previous seasons of Top Chef, I don't have a real rooting interest in any of the cheftestants this year. If I were forced to choose I would guess Richard is probably going to win (he's about as well-liked as Stephanie and more consistent). I—along with the rest of the world—loathe Lisa, but she's just kind of a bad trip, not really a boo-hiss, lie-to-your-face villain in the Tiffani/Omarosa mold. An interesting bit of data, for those Lisa-haters who suspect they are suffering from an irrational aversion to her attitude, looks, and posture: she has—by far—the worst record of any cheftestant to appear in a Top Chef finale (1 Elimination win, 1 place, no Quickfire wins; she has been up for elimination or on the losing team in the last seven consecutive episodes (!)). Incidentally, Richard (3 Elimination wins, 5 places, and 2 Quickfire wins) and Stephanie (4 Elimination wins, 5 places, and 1 Quickfire win) have by far the best records of any previous cheftestant, period. (In comparison, the previous three winners (Harold, Ilan, and Hung) had only 4 Elimination wins total.)

On the other side, BSG has been doing a lot of the mythical flim-flam (I don't really care where Earth is or whether they ever find it) and not so much of the intense post-9/11 fractured-mirror business that made the first three seasons so addictive. The characters have been getting pushed around the chessboard willy-nilly without much attention paid to consistency or plausibility (to wit: President Lee Adama), all in service of a presumed "mind-blowing" series finale (to arrive not before calendar year 2009, as I understand it) that I am quite certain will disappoint (I'm not going to be X-Files'ed ever again).

So there's your TV-blogging for the year. Back to work.

Wednesday, April 30, 2008

Linux Quickies


The upgrade from Ubuntu Gutsy to Hardy Heron (cool logo, right?) was relatively uneventful. Some minor points...


  • I always thought the main Ubuntu servers would farm my downloads off to an appropriate mirror, but apparently that's not the case. You're likely to get better download times if you choose a mirror in System -> Administration -> Software Sources. If you choose "Other...", there's a "Select Best Server" feature. Oddly, my best response times were from New Zealand... maybe because they were all asleep when I tried it.


  • The "ugly fix" for the infamous hard disk annihilating bug stopped working after I upgraded. This new, different (but still ugly) fix worked for me. It would be really great if the Ubuntu team could find a way to make the OS stop trying to kill my hard disk by default.


  • My WiFi light stopped working after the upgrade. This is very easily fixed by installing the package linux-backports-modules-hardy.


  • etckeeper is a great idea: it puts all the config files in /etc under Git, Mercurial, or Bazaar source control and forces APT to commit before and after any upgrade, so it's easy to isolate and revert changes. (As a side note, using Bazaar for a few weeks makes it physically painful to be forced to deal with CVS.)


  • Anti-aliased fonts in Emacs are really nice. On Ubuntu Hardy, install emacs-snapshot-gtk (on prior releases, downloads "Pretty Emacs"), then run emacs-snapshot instead of emacs (or run update-alternatives to set emacs-snapshot as the default). You should then be able to run, e.g., emacs --font "Monospace-10" and get pretty, pretty (lick-able, as they say) fonts. Other reasonable choices are "BitstreamVeraSansMono-X" or "LiberationMono-X", where X is your desired point size. You can also invoke M-x set-default-font and type your choice interactively, but for some reason the TrueType fonts above won't tab-complete—if you type a non-existent font, Emacs will silently use the default system fixed-width font (see System -> Preferences -> Appearance -> Fonts). I've added the following to my .emacs:

    (if (>= emacs-major-version 23)
    (set-default-font "Monospace-10"))

    (The conditional is necessary if you may come into contact with earlier versions of Emacs, which will barf on TrueType fonts.)


  • In my experience, the fonts in your web browser will look better if you don't use Microsoft's gratis TrueType core fonts (package msttcorefonts in Ubuntu/Debian). In particular, the Trebuchet font (which crops up frequently, including at the top of this page) tends to look pretty bad with subpixel rendering turned on. Red Hat's Liberation fonts (package ttf-liberation) are designed as drop-in replacements for the Microsoft fonts, but I haven't seen much value in installing them.


  • The instructions I gave last month for hooking up to a projector aren't complete, because they often won't let you run the projector at a resolution greater than 640x480. This led to a rather embarrassing scene in front a class of undergraduates, where OpenOffice.org simply refused to operate at such a pathetic resolution. This problem can be solved by the methods presented here, though it requires a bit of tweaking to get things just so. I haven't yet discovered a minimal solution—first I need to crack the meaning of the X11 "MetaModes" option. When I do, you'll be the first to know.

Tuesday, April 15, 2008

Only Thus Can It Be Unmade

The cleverer among you will espy the problem below immediately


$ export DATE=`date`
$ echo $(DATE)
bash: DATE: command not found

In my half-caffeinated state, it took several minutes of frustration to figure out what was wrong: $(DATE) is a Make-style variable; in Bash, $(DATE) is the same as `DATE` (a command substitution). The correct token is $DATE.

$ echo $DATE
Tue Apr 15 11:08:38 EDT 2008

I apologize for inflicting my stupidity upon you.

Thursday, April 03, 2008

On the Subject of Dementia

Ladies and gentlemen, I give you Mike Gravel, former Democratic and current Libertarian candidate for president. (Via Matthew Yglesias, who needs the traffic.)

Wednesday, April 02, 2008

Ted Turner is a Demented Genius

I now have a man-crush on Ted Turner. (I'm going to have to get in line behind Charlie Rose.) Charlie tries and tries, but Ted Turner has no truck with interrupters.

My favorite part is where they debate whether he should invite Rupert Murdoch to his birthday party. I'm not kidding! It's starts around 19:00. At 12:45, he sings an entire verse and chorus of "My Old Kentucky Home"! And Charlie just sits there with dewy eyes, like a bleach-blonde skank being serenaded by Bret Michaels!

UPDATE: The embed seems to have died, but the video is still at the Charlie Rose website.

Using an External Monitor or Projector With My Linux Laptop

For years, it was difficult enough to get my laptop working with an external monitor that I didn't even bother trying: I would boot into Windows in order to give a presentation. (This is the only reason I ever booted into Windows (or have a Windows install).) It either got dramatically easier to accomplish this at some point in the last year, or I've been incredibly stupid all this time. Just in case, here's how it works on my Dell Inspiron 6400 running Gutsy. My video card is an NVIDIA GeForce Go 7300


  1. Plug in the external monitor or projector. The monitor may work immediately (especially if you're repeating this step after fiddling about below), but it may be at the wrong resolution.


  2. Open "Applications -> System Tools -> NVIDIA Settings" or execute sudo nvidia-settings on the command line. This utility is provided by the nvidia-glx-new package, which you should probably have installed.


  3. Choose "X Server Display Configuration" and click "Detect Displays" at the bottom of the screen.


  4. The external monitor should appear in the Layout pane. Click on it, then click "Configure". Choose "TwinView" (which should hopefully not say that it requires an X restart).


  5. In the "Display" box, choose "Position: Clones". This means that you want the same display to appear on both monitors. This is what works best for me, particularly for giving presentations. Having separate displays seems to confuse applications—for example, "Presentation Mode" in Evince will "center" the slides, displaying the left half of a slide on the right half of the laptop screen and the right half of a slide on the left half of the projector. It's probably possible to tweak this with exactly the right viewport/workspace settings (ugh), but that's not how I roll.


  6. If the display is smaller than the default display—the display's square will be smaller in the Layout pane and the displayed area will be cropped on the screen—click on the
    default display in the Layout pane and choose a lower resolution. 1024x768 is usually safe. The laptop display will probably look bad, but the external display should look fine.

    Be careful: any smaller than 1024x768 and the Settings applet will be too big to display on the screen. If this happens, you'll have to navigate blind or hit Ctrl-Alt-Backspace to restart X (or don't automatically hit OK after the resolution changes and it will revert after 15 seconds).



To remove the external monitor or projector:


  1. Unplug the monitor.

  2. Click "Detect Displays".

  3. A message "The display device FOO has been unplugged..." will appear. Click "Remove."

  4. Click "Quit".



Under no circumstances should you click "Save to X Configuration File" at any point in this process. That's just asking for trouble.

Some sequence of actions—it's not clear which—may screw up the "X Server Display Configuration" pane. The display will
continue to function in the meanwhile, but all the above commands are inaccessible. Restarting X made it go away (for me).

[UPDATE] It seems it's necessary to update your xorg.conf to get decent resolution on some projectors. I'm still investigating... In the meantime, this should help.

Monday, March 24, 2008

LaTeX Appendectomies

I have need of a LaTeX package. I think a lot of people would find this package useful. I would prefer not to write it myself.

This package would take a mode argument in the preamble and format the document in one of three ways: as a conference submission, as a camera-ready conference paper, or as a tech report.

Suppose I have a theorem and that theorem has a proof.


  • In a conference submission, the theorem would appear in the main text and would be re-stated along with its proof in an appendix.

  • In a camera-ready conference paper, the theorem would appear in the main text and the proof would not appear at all.

  • In a tech report, the theorem and the proof would appear inline in the main text.


Preferably, proofs could be included in the main text or sent to an appendix on a case-by-case basis. Proofs could also have "sketch" versions and full versions: the sketch version appears in the main text of a conference paper (either kind) and the full version appears only in a tech report.

Suppose that, in proving a theorem, I first prove a lemma.

  • If the proof of the theorem appears in the main text (or an appendix), then the lemma and its proof should also appear in the main text (or the appendix), before the theorem.

  • If the proof of the theorem is omitted, or if a proof sketch is included which makes no reference to the lemma, then the lemma and its proof should not appear at all.



One should be able to conditionally include text depending on the mode. For example, in camera-ready conference mode, one would probably include the sentence: "Full proofs of all theorems appear in a technical report [citation here]."

The only package I've found that does anything like this is thrmappendix , but it doesn't allow for a proof to appear in the main text at all. It's primarily concerned with the appearance and re-appearance of the theorem, with or without its proof; I'm primarily concerned with the appearance or suppression of the proof.

Saturday, March 22, 2008

The Big House

Via Matthew Yglesias, the best, most practical government reform idea I've ever heard: increase the size of the House of Representatives.

In 1789, the House had 65 members, each representing about 30,000 constituents. That number grew consistently for the next hundred years. In 1913, the size of the House was fixed at 435 members. At that time, each member represented about 200,000 constituents. Since then, the population of the U.S. has more than doubled. The average size of a congressional district is now 700,000 constituents.

Increasing the size of the house and decreasing the average size of a district.would have the following salutary side effects:


  1. It would be cheaper to run for office, making more districts competitive and decreasing the need for fund-raising (and, thus, the influence of money).

  2. It would decrease the influence of individual law-makers, thereby decreasing the amount of money to be gained from corruption.

  3. It would make both Congress and the electoral college (which is based on congressional representation) more proportional and, thus, more little-D democratic.



To illustrate that last point, consider Wyoming and New York. Wyoming has about 500,000 residents, 1 House member, and 3 electoral votes. New York has about 19 million residents, 29 House members, and 31 electoral votes. A vote in a presidential election in Wyoming is worth about 3.7 times as much as a vote in a presidential election in New York. If we doubled the size of the House of Representatives, a vote in Wyoming would be worth only 2.5 times as much as a vote in New York. If we reduced districts to 30,000 constituents each (this is the lower bound specified in the Constitution and would yield a House with more than 10,000 members---picture the Galactic Senate in Star Wars, hopefully with fewer Gungans), a vote in Wyoming would be worth only about 1.1 times as much.

Now obviously that last scenario is not going to happen. In fact, it's hard to imagine the current Congress voting to make any change that would significantly reduce the influence of its own members. But the change doesn't have to be that dramatic: literally any increase would be a change for the good. And the population keeps increasing, so the problem will just get worse and worse. Why not shoot for, say, 50 new members after every census, with a target of keeping or slightly reducing the current average district size? It would not require a Consitutional amendment: the size of the House is determined by statute, just as the number, size, and shape of congressional districts are.

For more information, check out thirty-thousand.org.

P.S. While I'm at it, you may notice at left a badge for Change Congress, a somewhat goo-goo attempt by Lawrence Lessig for create a movement to political reform. I'm not sure exactly how I feel about this (just as I wasn't sure, as much as I admire Prof. Lessig, whether I really though he should run for Congress), but, if it doesn't cost me anything, I might as well cast my lot with the wild-eyed dreamers of the world.

Tuesday, March 11, 2008

Flashdance

Here's a video of me talking about Flashdance—a movie I had never seen before and plan to never see again—with my old friend Jonathan Betzler.

You know, I don't think I've seen myself on video in ten years or more (I like to remember things my own way. Not necessarily the way they happened) and I find this... surprisingly un-excruciating. Maybe it's a trick of the light.

Jonathan is threatening to do 23 more of these through the end of the year. (Last week was The Right Stuff. The rest will be posted here.)

Wednesday, February 06, 2008

The Crank Becomes the Cranked, Part 2: The Gloating

The media did all they could for the last month to make this a winner-take-all race, but now everybody wants to talk about delegates. Go Obama! W00t!

Kids These Days: Prepare Yourself for the Final Quest

Why are the Bad Brains on MTV? (Seriously.) Am I so far out I'm back in again?

Sunday, January 27, 2008

The Crank Becomes the Cranked

Thank you, New York Times!


Given Democratic rules, it is entirely possible for one candidate to win a majority of Feb. 5 states, and enjoy the election night ratification that comes with a TV network map displaying the geographic sweep of that person’s accomplishment, while his (or her) opponent ends the night with the most delegates.

On the Republican side, it is possible for one of the candidates to win the overall popular vote in California, but end up with fewer delegates than a rival, since most of the delegates are awarded in winner-take-all Congressional district races.


Read the whole thing (as they say).

Thursday, January 24, 2008

The Triumphant Return of C-c C-t

The upgrade to Ubuntu gutsy and/or Emacs 22 broke my favorite feature of tuareg/ocaml-mode: C-c C-t for "show type" in OCaml buffers (this requires compiling with -dtypes, which generates type annotation files). I suffered without this for a length of time which is either embarrassing or impressive, depending on whether you consider poking around inside Emacs Lisp files a productive or unproductive use of time...

I finally broke down and fixed it today. The problem is simply that Emacs and OCaml packages aren't cooperating properly. My solution, which may or may not be optimal, is as follows:


  1. Copy the directory /usr/share/emacs/site-lisp/ocaml-mode to a path of your choosing, say ~/.emacs.d/emacs22/ocaml-mode. Let's call this directory DIR
  2. (Optional) In Emacs 22, execute C-u 0 M-x byte-recompile-directory and choose DIR.
  3. Add the following line to your .emacs file:
    (or (< emacs-major-version 22) (push "DIR" load-path))



The test for whether it worked is: load a .ml file and type C-c C-t. In the mini-buffer, you'll either see "type: ..."; "Point is not within a typechecked expression or pattern"; or "No annotation file..." If it says "C-c C-t is undefined", then you have failed.

Sunday, January 20, 2008

The Delegate Strategy

So, yeah, I'm a crank, but I'm not alone:


At the end of the day, you need delegates to win. A strategy to win delegates seems like a smart strategy.


The current fake tally is:

Democrats
Clinton: 3
Obama: 1
Edwards: 0

Republicans
Romney: 3
McCain: 2
Huckabee: 1

The current real tally is:

Democrats
Obama: 38
Clinton: 36
Edwards: 18

Republicans
Romney: 59
McCain: 41
Huckabee: 26

So who's the front-runner again?

That said, less than 3% of the total delegates have been allocated on the Democratic side (it's about 6% on the Republican side—presumably because red states like South Carolina and Wyoming get proportionately more delegates). What I expect will happen is that Clinton (and probably Romney) will win a slim majority or plurality February 5 ("Super Tuesday") and more-or-less clinch the nomination. (I am willing to make a wager on that proposition. Anybody?)

In the end, I don't think the "emotional moment" in New Hampshire or "momentum" have much to do with Clinton's success. I think she has solid, proven support amongst the Democratic electorate, which just happens to be slightly larger in magnitude than Obama's.

In retrospect, the real question will be: why did Obama do so well in Iowa? With Huckabee, you can point to the evangelical factor. What's the deal with Obama?

Tuesday, January 15, 2008

Eye of the Tiger

Does anybody know which new API in Mac OS X 10.4 is the reason I can't use iLike the Amazon MP3 Downloader on my Power Mac G4? Any can anybody tell me why it sucks?

Believe it or not, I actually can't upgrade to 10.4, because it only comes on DVD-ROM and my, ahem, 6 year old G4 doesn't have a DVD-ROM drive. (You can get CDs if you buy a copy of 10.4 and send Apple a check for ten or fifteen bucks, but... eh, no.) I will not be buying a new computer this year.

Wednesday, January 09, 2008

New Hampshire Was a Tie?

Via Andrew Sullivan comes this strange and interesting fact: Barack Obama was awarded more delegates (12) in New Hampshire than Hillary Clinton was (11). Despite the fact that the media covers the primaries as win or take all contests—and, thus, Clinton was victorious and Obama came in second—by the delegate apportionment metric the contest was a tie: they each got 9 pledged delegates. For some reason, Obama has one extra superdelegate, so he came out slightly ahead.

In fake terms, the tally is 1 for Obama, 1 for Clinton. In real terms, the tally is 25 for Obama, 24 for Clinton, and 18 for Edwards. (In really real terms—because the superdelegates are seemingly predetermined—the tally is 183 for Clinton, 78 for Obama, 52 for Edwards.)

On the Republican side, note that Mitt Romney—who "lost" two contests in a row—has the delegate lead with 24 to McCain's 17 and Huckabee's 14. If he keeps losing like that, he'll win.

The takeaway from all of this is that the way we choose presidential candidates in this country is deeply and truly weird. Not only is the media narrative disconnected from the simple human and intellectual reality of the campaign (so that getting choked up becomes an emotional breakdown, or saying something sensible becomes a "gaffe"), it is disconnected from the political reality of the process: the one and only thing that matters here is who has more delegates. But instead we get to hear about who came in first and who cam in second and by how much and how that makes everybody feel...