Search code examples
algorithmformulapopularity

Formula for popularity? (based on "like it", "comments", "views")


I have some pages on a website and I have to create an ordering based on "popularity"/"activity"

The parameters that I have to use are:

  • views to the page
  • comments made on the page (there is a form at the bottom where uses can make comments)
  • clicks made to the "like it" icon

Are there any standards for what a formula for popularity would be? (if not opinions are good too)

(initially I thought of views + 10*comments + 10*likeit)


Solution

  • There is no standard formula for this (how could there be?)

    What you have looks like a fairly normal solution, and would probably work well. Of course, you should play around with the 10's to find values that suit your needs.

    Depending on your requirements, you might also want to add in a time factor (i.e. -X points per week) so that old pages become less popular. Alternatively, you could change your "page views" to "page views in the last month". Again, this depends on your needs, it may not be relevant.