I am working on a site where there are nodes that users can vote on (upvotes/downvotes). Each node has a list of subnodes. Users can vote on each of these subnodes as well. Think of the relationship between posts and comments on reddit.
What ranking algorithms are there that will help me sort nodes based on their own score as well as the score of their subnodes? I've looked at the reddit ranking algorithm for "hot" but unfortunately I don't see how I would factor in subnode ranking.