Ranking a set of objects: a graph based least-square approach