New Ranking Criteria - Percentage

you will find here.
bsebire
.
Posts: 25
Joined: Sun Nov 28, 2010 10:45 am

New Ranking Criteria - Percentage

Postby bsebire » Tue Jan 04, 2011 12:17 pm

Has anyone created a new ranking percentage criteria calculated by PointsFor/PointsAgainst ? or could advise how to create it ?

User avatar
timoline
Joomleague Core Developer, Donator
Joomleague Core Developer, Donator
Posts: 3331
Joined: Thu Mar 12, 2009 8:03 am
Contact:

Re: New Ranking Criteria - Percentage

Postby timoline » Tue Jan 04, 2011 1:17 pm

bsebire wrote:Has anyone created a new ranking percentage criteria calculated by PointsFor/PointsAgainst ? or could advise how to create it ?


How should this creteria be named? points avg ?

or do you mean scorefor and scoreagainst?

bsebire
.
Posts: 25
Joined: Sun Nov 28, 2010 10:45 am

Re: New Ranking Criteria - Percentage

Postby bsebire » Tue Jan 04, 2011 10:14 pm

Points percentage would do. It is calculated by dividing the Pointsfor by the Pointsagainst and multiplying by 100. eg
Team A - Total points for - 120
Team A - Total points against - 75
Points percentage = 120/75 x 100 = 160%

Thanks

User avatar
timoline
Joomleague Core Developer, Donator
Joomleague Core Developer, Donator
Posts: 3331
Joined: Thu Mar 12, 2009 8:03 am
Contact:

Re: New Ranking Criteria - Percentage

Postby timoline » Wed Jan 05, 2011 8:08 am

ok, but whats pointsfor and pointsagainst?
Example soccer game

Team A plays 4 matches
2 won, 1 draw, 1 lost
6 pts, 1 pts, 0 pts

total pointsfor=6
total pointsagainst=5 (=neg_points)

points perc. 6/5 x 100=120% ?

Is this correct?

bsebire
.
Posts: 25
Joined: Sun Nov 28, 2010 10:45 am

Re: New Ranking Criteria - Percentage

Postby bsebire » Wed Jan 05, 2011 10:39 am

I'm seting my site up for Australian rules football. In our game the we have goals worth 6 points, behinds worth 1 point. (but I'll worry about these at a later date).

A match score might be:-
Team A - 6 goals 3 behinds = 39 points (points for)
Team B - 5 goals 4 behinds = 34 points (points against)

To calculate percentage we need to take the total points for and divide by the total points against * 100. In the bove example it would be 39/34 x 100

Sorry, I appear to have confused you. The application already has the two points fields - JL_FOR & JL_AGAINST. All we need to do is divide JL_FOR by JL_AGAINST and multiply by 100.

In your example the percentage would be for = 7 (6+1) divided by against = 4 (1+3) *100

User avatar
timoline
Joomleague Core Developer, Donator
Joomleague Core Developer, Donator
Posts: 3331
Joined: Thu Mar 12, 2009 8:03 am
Contact:

Re: New Ranking Criteria - Percentage

Postby timoline » Wed Jan 05, 2011 11:15 am

Its indeed very confusing...

JL_FOR=Score For
JL_AGAINST=Score Against

Keep in mind Score is something different then Points

so it has nothing todo with points?

bsebire
.
Posts: 25
Joined: Sun Nov 28, 2010 10:45 am

Re: New Ranking Criteria - Percentage

Postby bsebire » Wed Jan 05, 2011 1:15 pm

Yes, sorry. I confused myself. Scorefor/scoreagainst x 100 is what I'm after.
It is somewhat difficult adapting to common terms used for soccer that we dont use for Australian Rules. But I'm getting there ..... slowly

User avatar
timoline
Joomleague Core Developer, Donator
Joomleague Core Developer, Donator
Posts: 3331
Joined: Thu Mar 12, 2009 8:03 am
Contact:

Re: New Ranking Criteria - Percentage

Postby timoline » Wed Jan 05, 2011 4:30 pm

bsebire wrote:Yes, sorry. I confused myself. Scorefor/scoreagainst x 100 is what I'm after.
It is somewhat difficult adapting to common terms used for soccer that we dont use for Australian Rules. But I'm getting there ..... slowly


http://bugtracker.joomleague.at/redmine/issues/637

User avatar
timoline
Joomleague Core Developer, Donator
Joomleague Core Developer, Donator
Posts: 3331
Joined: Thu Mar 12, 2009 8:03 am
Contact:

Re: New Ranking Criteria - Percentage

Postby timoline » Thu Jan 06, 2011 4:06 pm

one more question

you want it as ranking criteria or as an ranking row?
or both?

bsebire
.
Posts: 25
Joined: Sun Nov 28, 2010 10:45 am

Re: New Ranking Criteria - Percentage

Postby bsebire » Thu Jan 06, 2011 10:08 pm

Ranking criteria and column to display please

User avatar
timoline
Joomleague Core Developer, Donator
Joomleague Core Developer, Donator
Posts: 3331
Joined: Thu Mar 12, 2009 8:03 am
Contact:

Re: New Ranking Criteria - Percentage

Postby timoline » Thu Jan 06, 2011 11:19 pm

bsebire wrote:Ranking criteria and column to display please


committed, please check if it works.

bsebire
.
Posts: 25
Joined: Sun Nov 28, 2010 10:45 am

Re: New Ranking Criteria - Percentage

Postby bsebire » Fri Jan 07, 2011 1:46 am

Sorry to be a pest, but from where do I get the file ?

bsebire
.
Posts: 25
Joined: Sun Nov 28, 2010 10:45 am

Re: New Ranking Criteria - Percentage

Postby bsebire » Mon Jan 10, 2011 9:49 pm

Perfect, thanks.

User avatar
Vinceo
Newbie
Posts: 10
Joined: Fri Oct 15, 2010 6:21 pm
Location: Montpellier
Contact:

Re: New Ranking Criteria - Percentage

Postby Vinceo » Sat May 07, 2011 9:58 am

Hi, where can i find/download this ranking ? It's for my NFL and NBA fantasy league.
Thanks a lot

User avatar
timoline
Joomleague Core Developer, Donator
Joomleague Core Developer, Donator
Posts: 3331
Joined: Thu Mar 12, 2009 8:03 am
Contact:

Re: New Ranking Criteria - Percentage

Postby timoline » Sat May 07, 2011 10:12 am

i think its in the latest beta...
Joomla 1.5.x
Joomleague 1.5.....latest git version


Return to “Tips, Tricks, SourceCodeChanges”

Who is online

Users browsing this forum: No registered users and 2 guests

cron