Closed (won't fix)
Project:
Fivestar
Version:
6.x-1.19
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
12 Jul 2008 at 20:00 UTC
Updated:
10 Apr 2016 at 13:37 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
quicksketchI'll let Eaton consider this. I'm not sure where this "Total score" would really show up, other than in Views. It's easy enough to retrieve this score manually by using VotingAPI's functions to retrieve the current votes on a node then doing the math yourself.
Comment #2
totaldrupal commentedThanks for considering it. I really like the module but my main issue for a "total score" option is in sorting the view. If you want to show which node is most popular sorting by total votes or number of stars does not reflect it well. If you sorted by votes, it's possible for a node to have 100 votes for one star and be at the top. And if you sorted by stars it could have five stars and only one vote and be at the top. Do you see my problem in trying to show most popular?
Comment #3
ahoeben commentedI agree with the feature request. (I'ld say '+1' if it weren't for certain people's dislike for doing so ;-)
This feature is necessitated by a usability issue with the 5 star rating concept. If a user thinks a node does not even deserve 1 star, no vote will be cast, even though the user means to give it 0 stars, or a score of 0%. I am not saying that 5 star voting should somehow be changed, but votingapi could be changed to cater for this situation.
Code changes would be mostly in 'votingapi_views.inc', unless it is decided to add a cached value for the accumulated score.
Comment #4
Scott Reynolds commentedThis sounds to me like a FiveStar module thing.
For totaldrupal's issue, FiveStar should be able to do both Avg voting and Points voting. Points would reflect the number of stars selected and Avg would reflect the perctange from the translated stars
@ahoeben
Not sure that this is what this issue is about at all. You confused me :-D. But to your point, shouldn't FiveStar allow 0% ?
I suggest quicksketch to reconsider this...
Comment #5
quicksketchFivestar will never support points. Stars make no sense for this purpose. You can't average "points" into something like "3.5 stars", it's a completely different ranking system. Also, note that neither Amazon nor iTunes (or any other voting system I've ever seen) supports voting "0 stars".
I also realized my initial suggestion of (number of stars) * (number of votes) doesn't make any sense either. In such a system, something that received 6 single stars would rank higher than something that had 1 five star ranking.
Comment #6
ahoeben commented> In such a system, something that received 6 single stars would rank
> higher than something that had 1 five star ranking.
This actually *does* make sense. You have to wonder why 5 out of 6 persons who voted one star for a node did not think that that other node was worth any stars.
Comment #7
Scott Reynolds commentedSorry if I wasn't clear. I setting would be introduced, that tells FiveStar what votingapi type it is (avg, or points). If points was selected, it would use votingapi point system and thus 3.5 stars = 3.5 points? Thus you can get the count of points (2 votes, 1 with 2 stars and the other with 4.5 stars, the votingapi sum result is 6.5). There is no 'average' in points system.
That gives you a simple metric to gauge the popularity of a node. If a node has one vote but its 5 stars, it would be lower then the node with 6 votes with 1 star.
Is that desirable? Not sure. Lots of better solutions out there. All of the other solutions would involve creating a different votingapi calculation module that hook_votingapi_calculate().
This feels like one of those things that just is over-thought idea. My only thought is maybe FiveStar would want to use points system in votingapi. maybe
Comment #8
totaldrupal commentedYes, I think your idea above would work. If stars were points and the "total score" would be the sum of the points. Sorting could be based on the sum of the points.
Comment #9
ahoeben commentedIMHO, 'percentage' or 'points' is a tom[A]to/tom[ah]to thing. Having an option in fivestar to use points would solve my current problem though, so I support that idea.
Ofcourse it could break horribly if you change from one setting to the other if votes have already been cast...
Comment #10
quicksketchIf anyone can provide any existence of a point-based star system that might be helpful. I generally dismiss the idea because people are stretching the concept of what star rating systems are used for. Digg is not stars, Vote up/down systems are not stars. The good reason being that stars are not very suitable to that cause.
Comment #11
Scott Reynolds commentedthere datasets: http://www.grouplens.org/node/73 are all in number of stars. I would take that as meaning the movielens site uses points as well. Netflix as well... but you have to sign up for that data set. You can see the breakdown here: www.cs.pomona.edu/classes/cs062/assignments/asgt12.pdf
In actuality, points system makes quite a bit of sense in terms of stars. Percentage is actually more artificial in a sense, (not the least of which is because it requires that you do math to come up with the value). where points would just be a straight write to the db.
And to the point of changing from points to percentage and vice-versa, thats really simple. you know the range of points, and you have all the votes. You just translate 3 points (out of 5) into 3*.2 = .6.
Having thought about it some today, I happen to feel that it is more natural to consider stars in this manner then in percentage.
Comment #12
quicksketchI'm not implementing this. Patches will be considered.
Comment #13
paganwinter commentedIs it possible/easy that the fivestar code can be cloned to do something like that. That is, store points instead of percentage.
I am looking for functionality like Blogger's "Reactions". It's more like a poll, which shows the total no. of votes for each poll option (which can be emulated with stars and the little description that goes with each star).
Comment #14
ezra-g commentedI marked #891854: Support 'points' or other non "percent" value_type as a dupe of this. Seems like there's a reasonable amount of demand for this feature.
Comment #15
ezra-g commentedThis may need some revision in fivestar.js, but here's what a site-wide setting would look like.
Comment #16
weka commented+1
Comment #17
weka commentedI wanted to test your patch ezra-g so I applied it against the latest 6.x-2.x-dev available through the Releases for Fivestar page but the patch failed with errors.
Hunk #1 FAILED at 311.
Hunk #2 FAILED at 358.
Hunk #3 FAILED at 705.
3 out of 3 hunks FAILED
Of-course I may be doing something wrong ;-)
Comment #18
ezra-g commentedIgnore this comment and patch, I meant to post this at http://drupal.org/node/786224#comment-4049938
Comment #19
weka commentedMarked #594868: Support different values? as a duplicate of this feature request.
Comment #20
ezra-g commentedHere's a revision that addresses some situations where we would divide by 100 if the value type were percent, but not if it were points. This results in vote point values corresponding to the star number, rather than those values normalized between 0 and 100.
This also changes the value_type to radios, rather than a free entry text field so folks don't get too crazy with the value here.
I've verified that this applies the latest of the 2.x branch from CVS.
Comment #21
ezra-g commentedThis revision adds some changes to the frontend (mainly fivestar.js) to account for points instead of percentages.
This could use more testing in both points and percentage modes.
Comment #22
weka commentedThank you for the patches Ezra, I will test these as soon as possible.
Right now as a workaround I am using the Views Custom Field module to recalculate the percentage back to points. Unfortunately only the DEV version supports sorting using the custom PHP field.
Comment #23
Taxoman commentedComment #24
ericduran commentedMoving back to 6.x there's already a patch in the queue. That should at least be tested and review.
Comment #25
sappling commentedIs this supposed to be supported in 6.x-1.19? I see a "Total score" aggregation function there, but it does not seem to work. I always get a value of 0 as a result.
Comment #27
Energyblazar commentedjust a suggestion why dont you guys user Voting Rules module along with rules and fivestar.....then u can do anything with fivestar...
Comment #28
whiteph commentedSorry, Drupal 6 is end of life, and is no longer supported.