Rating Rating
 

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Main Menu

Rating

Started by ibanez, December 05, 2006, 12:39:50 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

ibanez

Hello,
cpg rating system is insufficient! Please visit www.fotokritik.com
Rating system example:
rating1=-1
rating2= 0
rating3=+1
rating4=+2
rating5=+3
rating6=+4

for example 5 person
2+1+2+(-1)+3=7/5=1.4
can we recreate generate plug-in or code

Best regards

ibanez

we need geometric calculate!

Joachim Müller

OK, you're welcome to modify the code accordingly - go ahead.

ibanez

Quote from: GauGau on January 05, 2007, 09:34:29 AM
OK, you're welcome to modify the code accordingly - go ahead.
Formul is attached
example:
1.user 4 point
2.user 3 point
3.user 4 point

³√4x3x4




ibanez

okey
Formula:

a=user1(rate)*user2(rate)*user3(rate)
a=4*3*4
n=votes
n=3
pow(a,1/n)=3.6 Geometric Average

How is PHP code?


ibanez

open ratepic.php
and find
$new_rating = round(($row['votes'] * $row['pic_rating'] + $rate * 2000) / ($row['votes'] + 1));
and replace
$new_rating = pow( ( pow($row['pic_rating'],$row['votes'])*$rate*2000) , (1/($row['votes']+1)) );
that's all

rating = geometric average