this post was submitted on 16 Jun 2023
10 points (77.8% liked)
General Programming Discussion
8050 readers
1 users here now
A general programming discussion community.
Rules:
- Be civil.
- Please start discussions that spark conversation
Other communities
Systems
Functional Programming
Also related
founded 5 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
Something is controversial if there is a variety of opinions. You can use the variance to quantity that. In this case, it's just upvotes and downvotes so maybe there's a simpler way to calculate variance for that case.
Controversiality = upvotes / total votes?
The maximum value of this is 1 and the smallest value is 0. As written, if every person upvoted a post, it would be 1, but not controversial, so that wouldn't work. Say you slightly modified it and used downvotes / total votes, at first glance it seems sensible because then if everyone upvoted, you get 0, indicating that it's not at all controversial, a sensible result. But if everyone downvotes it, you get 1, indicating maximum controversy, but there was no controversy. Everyone agreed it was bad.
With variance, if something is unanimously liked or disliked the variance is 0. If it's split 50/50, the variance is greatest. You want something to adjust for the sample size, so you could use variance * total votes. It is similar, if not identical, to a binomial distribution.