views:

439

answers:

3

I need to sort some products base on user ratings.

Suppose we have 3 products {a,b,c} and we have user's feed backs about this products. It's not important which user give us feed back (this question is not about correlative filtering if you are familiar with it - user interests is not the case here)

Each of these below lines are feed backs from users when they tried to compare the 3 products:

a 150 points - b 0 points (this user just told us what he thinks of 2 products a and b and in comparison of a and b he though that if he gives a 150 point then b worth 0 point)

a 150 points - c 20 points

c 200 points - a 10 points (despite the previous one this user thinks that c is better that a)

a 200 points - b 40 points - c 100 points

a 150 points - b 50 points

a 150 points - b 20 points

(These ratings are just a sample and in the real world number of products and ratings are much bigger than this)

Now I need an algorithm to find product's rankings based on user votes. In my point of view the best way is to describe this problem with a correlation graph and connect all products to each other.

Any kind of help or tips is appreciated.

/******************************************************************************/**

you cannot just add the points and calculate the mean of product's points Cause it's important how it got his points suppose a has got 800 points against b - then c get 10 points against a like this:

a 200 - b 0

a 200 - b 0

a 200 - b 0

a 200 - b 0

c 10 - a 0 (this means that c is better than a)

so definitely a is better than b but with a small 10 points c got a better rank from a

/****************************************************************************/

+2  A: 

A baysean rating system might be your best bet - it takes into account the votes and the relative number of votes an item has in order to give it a weighted score.

Mr. Matt
The baysean rating system works when elements are rated, but not when they are rated in relation to other elements.
Ralph Rickenbach
+2  A: 

You have some challenges. Add a ranking c 0 - b 20 and you got a circle, where c < b < a < c.

And of course your order is not only not transitif ( from a < b < c does not follow a < c ), it is also not total (there might be elements you cannot decide which is better because no user voting has been done, even through other elements.

What you get is a disconnected, directed, finite graph. (use the direction of the edges to say which element(node is better).

Starting at a certain node you can find better nodes marching through the graph, maybe finding multiple non comparable solutions. If you visit the starting node again, stop processing that path.

Maybe order theory in math can help you: look for order theory, partial order, Hasse diagram.

To make this more practical:

Use a two dimensional array with a row and a column per element. In the cell(a,b) calculate the sum of the ratings. Starting at a certain element a, follow all positiv (>0) connections, until you either reach a node that has no positiv connections or come back to a node you visited already. These nodes are your solutions.

Ralph Rickenbach
A: 

I think you need to relate how each person voted on each product - for instance: person 1 voted: 100 for a, 50 for b and 0 for c person 2 voted 0 for a, 200 for b and 80 for c

this should be translated into:
person 1 voted 3 for a, 2 for b and -1 for c
person 2 voted -1 for a, 3 for b and 2 for c

where I'm using:
3 for the highest vote
2 for the second highest
1 for the lowest
AND -1 if they voted 0 (indication that they disliked/did-not-consider the product)

my initial thought on it anyway

meade