I'm sure it varies from program to program.
Ours generally started with a certain weight being given to each applicant based on scores, grades, and interviews.
The residency secretary would put this into a power-point presentation. A slide consisted of a giant picture of you, with pertinent information underneath (scores, grades, ER grades, where they're from, etc.)
At that point, the residents sat around and had a blast making fun of people and moving people up or down on the rank-list for good, or not so good reasons (There were a lot of, "HEY! She's hot, put her up like 20 spots!" groans from the girls in the room- "No, seriously, she was really...personable the night before.) People would get put up for getting along during the pre-or post-interview interaction with the other residents. People would get DNR'd for stupid behaviour (I recall one guy who made a borderline racist comment that led to his demise). "They would really fun to drink beer with" or "They would totally fit in here" was a common comment. There were some people who were DNR'd for out of control behavior, or excessive drinking on the other hand.
There were always two camps in our meetings.
First, the people who like good grades and high scores, and would be willing to go for hard-working nerds, who were nice people.
Second, the people who seem to make it their goal of getting friends/lovers/bar-mates, with equally low board scores and grades, but who were "cool".
In general, it is a very random process, with a lot of people who plummet 30 or 40 spots just because nobody remembers them well, or they have a bad hair-cut. The residency director was there with us and got our feed-back and wrote notes on people.
After we were done playing god with people's futures (it really is a power trip), the attendings would all meet and go over our rank list and change it as they saw fit. In the end, I'm not sure how many people that got put at the top of the list stayed there, but I think the bottom of the list, and the DNR's put in place by the residents are pretty much adhered to.