News for hackers. Stuff that matters.
Re:How Not To Sort By Average Rating by spolsky on Thursday February 12, 2009 @02:45PM (#478872)
Speaking of Amazon -- I'd rather buy a book with lots of 1s and 5s than a book with straight 3s. Wouldn't you?
Re:How Not To Sort By Average Rating by marcus on Thursday February 12, 2009 @03:26PM (#478931)
Hmm that depends on the book and who posted the 1s and the 5s, you just described the ratings of every scientology book and every evolution book in amazon.

But I agree that while there is a decent chance that a book with lots of 5s and lots 1s will be of value, the chances that a book with straight 3s to be worth anything are pretty slim.

Re:How Not To Sort By Average Rating by iamwil on Thursday February 12, 2009 @06:15PM (#479153)
And Wolfram's "A New Kind of Science", if I remember correctly.
Re:How Not To Sort By Average Rating by mhartl on Thursday February 12, 2009 @10:45PM (#479394)
And SICP.
Re:How Not To Sort By Average Rating by fgimenez on Thursday February 12, 2009 @03:25PM (#478928)
So you'd rather sort by variance?

I don't see why (outside of security issues) we can't just define our own sorting functions for a site.

Re:How Not To Sort By Average Rating by alexandros on Thursday February 12, 2009 @04:10PM (#478992)
This is a dream of mine as well, but performance may be a problem. Custom functions mean no caching and arbitrary computational burden from each function.
Re:How Not To Sort By Average Rating by ars on Thursday February 12, 2009 @07:06PM (#479208)
It doesn't have to be totally custom. Just solicit a few representative types and allow all those. This also solves the problem of not everyone knowing how to write such a function, and dealing with user code running on the server.
Re:How Not To Sort By Average Rating by IsaacSchlueter on Thursday February 12, 2009 @11:51PM (#479455)
Better yet, play around with lots of different sorting methods, and look for patterns in the sorting method used (s), the user's data and history (h), and the amount of money the user ends up spending ($).

Maximize $, and don't ask stupid questions like "Would you rather sort by variance, average rating, or Wilson score?"

(I'm pretty sure that's what Amazon is busy doing every day. They're positively brilliant at turning data into money.)

Re:How Not To Sort By Average Rating by trezor on Friday February 13, 2009 @08:52AM (#479833)
Custom functions mean no caching

This only applies if you are using a sub-par database. While caching computationally heavy operations is not always a good choice (since they will need to get updated when more entries are added to the dataset), chances are you will have orders of magnitudes more lookups than writes and hence it makes sense to create a computed column and index the results (and hence cache them).

Re:How Not To Sort By Average Rating by blader on Thursday February 12, 2009 @06:39PM (#479179)
Because the vast majority of users out there can barely click a mouse, much less write code to define sorting functions.
Re:How Not To Sort By Average Rating by ca on Thursday February 12, 2009 @05:13PM (#479085)
In the case of Amazon, perhaps the Associates Web Service APIs could allow the creation of tool allowing user-defined sorting functions. I've never used these APIs, but I found some details on them that lead me to think it would be possible. See http://aws.amazon.com/associates/#details

That said, asking honestly, are you entirely convinced of the mass appeal of user-defined (or user-selected) sorting algorithms? I find that the current algorithm usually gives fairly sane results.

(Edit: rewrote last sentence for clarity)

Re:How Not To Sort By Average Rating by gojomo on Thursday February 12, 2009 @03:53PM (#478971)
Yes. And similarly, for sites like News.YC: I'd rather read a "2 points" comment with 100 upvotes and 99 downvotes, than something banal with one upvote.
Re:How Not To Sort By Average Rating by sofal on Thursday February 12, 2009 @04:05PM (#478983)
Comments like that are frequently dogmatic assertions about down-the-middle controversial issues (like religion or politics) that draw knee-jerk up/down votes from the two ever-combative groups. The comments with one upvote can sometimes be hidden gems in an abandoned thread, or possibly one great comment among many others.
Re:How Not To Sort By Average Rating by gojomo on Thursday February 12, 2009 @06:16PM (#479158)
They can be. But if they are shallow, dogmatic assertions, they often (and should) go negative and stay negative.

I've seen lots of good, fair comments with strong opinions (whether I agree with them or not) go initially negative -- early downvotes from the anonymous censorious underemployed peanut gallery -- then creep back up to small positive values after a full day's cycle. Those are much better comments than any pandering +20 one-liner.

Re:How Not To Sort By Average Rating by brianr on Thursday February 12, 2009 @03:24PM (#478926)
Maybe Amazon can implement "Sort by Kurtosis" :)

http://en.wikipedia.org/wiki/Kurtosis