print_fbRanks: Printing function for fbRanks Objects

Description Usage Arguments Value Author(s) Examples

Description

The rank.teams function outputs fbRanks objects. print(fbRanks)., where fbRanks is one's output from a rank.teams call, will print out the rankings for each cluster of teams in the match data.

Usage

1
2
3
## S3 method for class 'fbRanks'
print(x, ..., scaling="median total", base=2, 
        log.transform.attack=FALSE, header=TRUE, silent=FALSE, type="", file="")

Arguments

x

A fbRanks object.

...

Other filters to apply when printing. These must match column names in either x$teams or x$scores. For example, if x$teams has a column named 'country' with values 'UK','Canada' and 'Germany', you can pass in country="UK" to only show UK ranks.

scaling

How to scale the ranks. By default, they are scaled with 0 at the median team in the database. Pass in a number to scale to that number.

base

By default, the ranks are shown base(2) but you can other bases. Pass in exp(1) to change to base e.

log.transform.attack

Whether to show the attack and defense scores as logged transformed.

header

Whether to add some header information to the print out.

type

If type="html", html of the ranks table is output.

file

If type="html", then the output can be output to a file.

silent

If FALSE no output but the ranks are returned.

Value

A print out of team ranks.

Author(s)

Eli Holmes, Seattle, USA.

eeholmes(at)u(dot)washington(dot)com

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
 
#This loads two data frames: B00.scores and B00.teams
data(B00data)
#rank the teams in the RCL D1 league
x=rank.teams(scores=B00.scores, teams=B00.teams, venue="RCL D1")

#Just a printing of the ranks with no extra info shown.
#some 2 team clusters are shown.  Those are teams with just 1 game (against each other)
print(x)

## Not run: 
#rank all teams
x=rank.teams(scores=B00.scores, teams=B00.teams, venue="RCL D1")

#You can also do filtered prints
#print the ranks with the regions shown
print(x, region="all")

#print ranks for just a region
print(x, region="WA")

#print ranks for a league; fall.league is a column in the teams data frame
print(x, fall.league=c("RCL D1 U12","RCL D2 U12"))

#print ranks for teams in a tournament; venue is a column in the scores data frame
print(x, venue="Baker Blast")

## End(Not run)

fbRanks documentation built on May 1, 2019, 8:01 p.m.