TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Ask HN: Algorithm for ranking comments in a post

7 点作者 manidoraisamy大约 10 年前
I like the way HN displays comments based on how recent it is and its upvotes. I am building a leaderboard that ranks people and looking for a similar algorithm. Can you explain the algorithm?

4 条评论

ohashi大约 10 年前
The other post mentions wilson confidence interval&#x27;s. Here&#x27;s the post I learned it from: <a href="http://www.evanmiller.org/how-not-to-sort-by-average-rating.html" rel="nofollow">http:&#x2F;&#x2F;www.evanmiller.org&#x2F;how-not-to-sort-by-average-rating....</a>
评论 #9196481 未加载
lugg大约 10 年前
<a href="https://news.ycombinator.com/item?id=1781013" rel="nofollow">https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=1781013</a><p><a href="http://amix.dk/blog/post/19574" rel="nofollow">http:&#x2F;&#x2F;amix.dk&#x2F;blog&#x2F;post&#x2F;19574</a>
manidoraisamy大约 10 年前
Here is my current algorithm:<p>DiffInDays = Today - Date_1970_1_1; &#x2F;&#x2F; Number of days between Today and Jan 1, 1970.<p>Rank = DiffInDays + (Score&#x2F;1000); &#x2F;&#x2F; Score is the equivalent of upvotes.<p>&#x2F;&#x2F; Sort by Rank
avargas大约 10 年前
You could create something based off reddit&#x27;s <a href="http://amix.dk/blog/post/19588" rel="nofollow">http:&#x2F;&#x2F;amix.dk&#x2F;blog&#x2F;post&#x2F;19588</a>